Re: remote access during runaway process
- From: Keith Keller <kkeller-usenet@xxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 4 Jan 2006 13:12:02 -0800
On 2006-01-04, Todd W <toddrw69@xxxxxxxxxx> wrote:
>
> On a remotely hosted Linux server, a developer's code went in to deep
> recursion, and all of the services on the system became unavailable,
> requiring a call to the hosting provider.
>
> I'd like to make it so ssh is still available in this situation.
>
> After some research (I'm much more of a developer than a sysadmin myself), I
> came up with putting "snice -20 sshd" in /etc/rc.d/rc.local, but I don't
> know for sure if this would give the desired results.
>
> Will someone please advise me as to whether this is okay or point me to the
> proper solution if I am way off base?
Well, it might work okay, but if your load starts hitting 20 or 30, even
sshd will go dog-slow. (I had this once--it took three minutes to go
from initial connect to shell prompt. Killing the process was even more
painful.) One other option might be to set up a serial console, but
you'll still run into the problem that you need to get a shell, find out
which process is going crazy, and kill it. The only potential advantage
is that, over a serial console, you might (*might*) be able to send
Ctrl-Alt-Del to the server, so that you can reboot without having to log
in and get a shell and issue shutdown -r. But doing a reboot may not be
a good option for you anyway.
Another potential solution is to use ulimits. If this is a command-line
program, ulimit the user's shell. If it's a CGI, ulimit (or RLimit)
apache (or the webserver). It won't make sshd more available, but it
will kill off the process automatically if it uses too much resources.
--keith
--
kkeller-usenet@xxxxxxxxxxxxxxxxxxxxxxxxxx
(try just my userid to email me)
AOLSFAQ=http://wombat.san-francisco.ca.us/cgi-bin/fom
see X- headers for PGP signature information
.
- Follow-Ups:
- Re: remote access during runaway process
- From: Michael Heiming
- Re: remote access during runaway process
- References:
- remote access during runaway process
- From: Todd W
- remote access during runaway process
- Prev by Date: Re: new graphic card problem
- Next by Date: Re: remote access during runaway process
- Previous by thread: remote access during runaway process
- Next by thread: Re: remote access during runaway process
- Index(es):
Relevant Pages
|
|