[Techtalk] Drupal and Apache

James Sutherland james at deadnode.org
Fri Jan 28 19:30:25 UTC 2011


On 28/01/2011 18:18, Michelle Murrain wrote:
> Hi all,
>
> I'm running into an interesting problem with a Drupal website. It's a
> graphic-heavy site with moderate traffic, on a VPS (slicehost). At one
> point, Apache was completely maxing out the CPU (although not the
> memory, which is much more often the problem.) It seems quite strange,
> actually - there was something that shifted to start maxing out the
> CPU, but I can't figure out what it was.
>
> I've reduced the MaxChildRequests from unlimited to 2000.
>
> One possible thing I thought of was to use the RLimitCPU directive -
> but I can't find great examples for what kind of values to use with
> this directive.

Two possibilities come to mind: one is if you are using mod_gzip or 
similar (obviously, compressing data is quite CPU heavy), the other 
would be PHP for Drupal itself.

Have you looked at the logfiles to see if anything unusual happened 
then? How long was the CPU maxed out - a few seconds/minutes, or did it 
stay maxed out for good or until a restart?

Apache is versatile, but quite heavy on CPU and memory; I switched to 
Lighttpd a few years ago, and was very happy with the results. Of 
course, every system has its limits, so a heavy enough 'Slashdotting' 
will max out even the most efficient site possible, but a bit of tuning 
can go a long way.


James.


More information about the Techtalk mailing list