Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

we are facing a problem,that new requests are not processed even if apache hasn't reached its max_client setting.

Max_client is set to 800
max_spare server is 36
min_spare server is 35
Timeout 300
keepalive on
keepalive timeout 10

Max_keep_alive_requests 100

Why is apache not processing new requests and sending timeouts evenif it hasnt reached its max_client value.

An strace revealed that around 80+ apache children is in idle state that is 0.0000 seconds in strace ouput.

Why this many children is in idle state and still generating new children,but stillnot processing request and sending timeout.

we are using Php5,Apache 2 with mpm-prefork,Mysql 5,Running on Ubuntu 11.04 with CSF firewall.

All the requests are made from single ip(our ip address).

Will too many request from a single ip result in any TCP/IP or Apache Restrictions to connect,result in denying new requests?

share|improve this question
Could you check error log after restarting apache? in many distributions prefork mode of apache compiled with 256 Limit of MaxClients. – Andrei Mikhaltsov Jul 13 '12 at 11:25
Not for many versions now - the defaults since 2.2.something are 1024 or 2048 for both. – adaptr Jul 13 '12 at 12:12

Why this many children is in idle state and still generating new children,but stillnot processing request and sending timeout.

"Nobody knows"

First of all, you need to understand that spawning new processes is VERY expensive in prefork.

To avoid doing that whenever possible, you configure the right parameters for your server load and expected traffic peaks.

To find out THAT, you go look at server-status and check what kind of load this actually is - is it bottlenecking on number of connections, keepalive, per-IP concurrency, bandwidth, backend proxy latencies, too few free processes - what ?

Get back to us if you have enabled server-status (and ExtendedStatus!) and understand what the output means.

share|improve this answer

it may be that you are sending multiple requests over the same connection from your testbed.

basically you setuped:

keepalive on
maxkeepaliverequests 100

so in this scenario, if you are generating multiple requests over the same connection, you hit the fan at 100 requests.

try with:

keepalive off


maxkeepaliverequests 0

note: your ServerLimit setting should also at least match MaxClients

share|improve this answer
Already tried with out keepalive but nothing changed... – ananthan Jul 13 '12 at 10:14
do you have some per-ip-address limits somewhere? either apache or maybe iptables? – sysfault Jul 13 '12 at 12:02
also, raise ServerLimit. If it's lower than MaxClients it will be respected. – sysfault Jul 13 '12 at 12:04
server limit is same as that of max_clients.. – ananthan Jul 13 '12 at 15:27

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.