Link to home
Start Free TrialLog in
Avatar of srollins
srollins

asked on

Apache-can't spawn child process

We are using Apache 1.3 and have these values set:

MaxClients 100
MaxRequestsPerChild 20

Yesterday, a user must have been leaning against the enter key and created over 200 processes causing the web server user 'nobody' to reach its max process limit and start giving the error 'can't spawn child' to new requests. What settings can I use to prevent this from occurring. Is there a setting that will just lock out the offender and not affect anyone else? I believe our AIX is set to allow 300, but read that httpd.h allows 256.
ASKER CERTIFIED SOLUTION
Avatar of triliji
triliji

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of srollins
srollins

ASKER

The "leaning again the enter key" causes the form on the screen to be submitted repeatedly because a carriage-return submits the form. Someone leaning on it would continuously submit the form over and over.

You say that I should be able to catch these errant overloads and kill some processes. How do I catch these overloads and how do I know which processes to kill. I don't want to kill a legitimate process that may be writing to the database.
What O/S are you using?
Do you presently have a program to monitor your sites
activity?

Is the form writing to a binary database or flatfile?
Killing a process can be pinpoint or shotgun
and it should not be hard to detect a runaway process.
Unless your site is receiving millions of hits you should
be able to notice an extraordinary increase in processes being
run.

You can use the kill pid for pinpoint or the
killall for shotgun but be careful not to run it
as root if you are the sysadmin or you could
cause some irreversible damage.

Is this a CGI script you are running?