httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ruediger Pluem <rpl...@apache.org>
Subject Re: strange usage pattern for child processes
Date Wed, 15 Oct 2008 12:41:40 GMT


On 10/15/2008 01:55 PM, Lars Eilebrecht wrote:
> Hi,
> 
> I'm trying to debug a performance issue on an Apache infrastructure
> using 2.2.9 as reverse proxies. The Apache servers don't do much
> except for ProxyPass'ing data from others backend servers, and
> caching the content using mod_mem_cache.

Is it really a good idea to use mod_mem_cache? Keep in mind that
mod_mem_cache uses local caches per process and cannot use sendfile
to send cached data. It seems that mod_disk_cache with a cache root
on a ram disk could be more efficient here.

> This is Apache with the worker mpm on Solaris. Currently each
> box is configured with a ServerLimit of 3. The attached screenshot
> of the server-status page shows that almost all threads of one
> child process (at the bottom) are in "W" state. The thread status
> of the process shown at the top look OK, but the second child
> process doesn't seem to be used at all. 
> The first odd thing is that I would have expected that Apache
> uses all child processes about equally. Especially I would
> have expected that there are at least 25 threads for the second
> process in state "_" (waiting for connection), because the
> MinSpareThread directive is set to 25. 

This is indeed strange. Mind to

1. Attach an ASCII-output of the whole status page to see the exact
   process / thread slot usage.
2. Your MPM configuration and your reverse proxy configuration.

> The second odd thing is that the connections/threads in W state
> seem to be hanging, i.e., no data is being transferred over the
> connection and these threads/connection time out after about 256
> seconds. However, the general Timeout setting is 30s so why
> isn't the connection killed after 30s?

It would be very helpful to have a backtrace of this process. If they
aren't killed after the timeout it is highly likely that they don't
wait for IO but do or wait for something else.

> What happens during peek times is that all threads of one
> child process end up in state W, then Apache starts using
> another child process, etc. and at some point basically
> all threads are in state W and we are hitting the MaxClients
> limit which makes the server unusable. 

Regards

RĂ¼diger


Mime
View raw message