You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Arnab Ganguly <ag...@gmail.com> on 2007/04/02 06:53:21 UTC

[users@httpd] Info when the MaxClient is reached

Hi All,
Want some info when the MaxClient value is reached, what would happen to
Apache webserver?Is that particular of time if we ping apache it will time
out.How long will it take to recover or the requests will be queued?
Can you tell me is there any configurable parameter in NES similar to
MaxClient settings in Apache.ie the max simulatenous request it can handle?
Looking forward for respone.
Thanks in advance.
-A

Re: [users@httpd] Info when the MaxClient is reached

Posted by Arnab Ganguly <ag...@gmail.com>.
Thanks for all the info.Once more thing wanted to ask if your refer to
worker.c I see once the idle_thread_count < min_spare_threads is met, the
error
"server reached MaxClients setting, consider raising the MaxClients
setting". Just wanted to know the relation between the idle_thread_count,
min_spare_threads and MaxClients.This error seems that all the workers are
busy and then there is nothing no idle worker.
Thanks in advance.
Regards
-A

On 4/2/07, Sander Temme <sc...@apache.org> wrote:
>
> Hi Arnab,
>
> On Apr 1, 2007, at 9:53 PM, Arnab Ganguly wrote:
>
> > Want some info when the MaxClient value is reached, what would
> > happen to Apache webserver?Is that particular of time if we ping
> > apache it will time out.How long will it take to recover or the
> > requests will be queued?
> > Can you tell me is there any configurable parameter in NES similar
> > to MaxClient settings in Apache.ie the max simulatenous request it
> > can handle?
>
> The MaxClients directive dictates the maximum number of child
> processes (prefork) or worker threads (other MPMs) Apache can spawn.
> Its name is slightly misleading: MaxClients does not actually dictate
> the maximum number of clients that can connect to the web server.  It
> does, however, dictate the maximum number of requests Apache can
> handle concurrently.
>
> As TCP connections arrive on Apache's listening socket, they are
> queued by the kernel.  All the Apache workers receive these TCP
> connections in the order in which they arrived.  If Apache handles
> the requests fast enough, the queue will be mostly empty and any new
> connection will be received by an Apache worker immediately.  If the
> server is busy, requests may queue up and the client's browser will
> say 'Connecting to... ' in the status bar.  The number of connections
> that can queue up is platform-specific, but you can manipulate it
> using the ListenBacklog directive:
>
> http://httpd.apache.org/docs/2.2/mod/mpm_common.html#listenbacklog
>
> Only when the kernel's queue is full, and all Apache children are
> busy will the server refuse new incoming connections, and the way in
> which this happens also depends on the server platform.
>
> Of course all of this happens on the Apache listening socket, and has
> nothing to do with ping (ICMP) which is handled completely inside the
> kernel.
>
> S.
>
> --
> sctemme@apache.org            http://www.temme.net/sander/
> Open Source Software Consultant
> PGP FP: 51B4 8727 466A 0BC3 69F4  B7B8 B2BE BC40 1529 24AF
>
> ApacheCon 2007 Europe, May 1-4 in Amsterdam
> http://www.eu.apachecon.com/
>
>
>
>
>

Re: [users@httpd] Info when the MaxClient is reached

Posted by Sander Temme <sc...@apache.org>.
Hi Arnab,

On Apr 1, 2007, at 9:53 PM, Arnab Ganguly wrote:

> Want some info when the MaxClient value is reached, what would  
> happen to Apache webserver?Is that particular of time if we ping  
> apache it will time out.How long will it take to recover or the  
> requests will be queued?
> Can you tell me is there any configurable parameter in NES similar  
> to MaxClient settings in Apache.ie the max simulatenous request it  
> can handle?

The MaxClients directive dictates the maximum number of child  
processes (prefork) or worker threads (other MPMs) Apache can spawn.   
Its name is slightly misleading: MaxClients does not actually dictate  
the maximum number of clients that can connect to the web server.  It  
does, however, dictate the maximum number of requests Apache can  
handle concurrently.

As TCP connections arrive on Apache's listening socket, they are  
queued by the kernel.  All the Apache workers receive these TCP  
connections in the order in which they arrived.  If Apache handles  
the requests fast enough, the queue will be mostly empty and any new  
connection will be received by an Apache worker immediately.  If the  
server is busy, requests may queue up and the client's browser will  
say 'Connecting to... ' in the status bar.  The number of connections  
that can queue up is platform-specific, but you can manipulate it  
using the ListenBacklog directive:

http://httpd.apache.org/docs/2.2/mod/mpm_common.html#listenbacklog

Only when the kernel's queue is full, and all Apache children are  
busy will the server refuse new incoming connections, and the way in  
which this happens also depends on the server platform.

Of course all of this happens on the Apache listening socket, and has  
nothing to do with ping (ICMP) which is handled completely inside the  
kernel.

S.

-- 
sctemme@apache.org            http://www.temme.net/sander/
Open Source Software Consultant
PGP FP: 51B4 8727 466A 0BC3 69F4  B7B8 B2BE BC40 1529 24AF

ApacheCon 2007 Europe, May 1-4 in Amsterdam
http://www.eu.apachecon.com/