Robin stepped in it again (robin_serrano) wrote in lj_everywhere,
Robin stepped in it again
robin_serrano
lj_everywhere

Need Advice on Server Specs & httpd.conf on a large install

First, thanks to chrisj for answering on my update question. I finally got through it, and things seem to be settling in again as far as functionality itself.

Now, I'm planning to upgrade to a brand new server, and I'm hoping to get opinions on that.

I have a large installation (relatively speaking, of course, and rather busy for an LJ clone site). We have 8800 users, get about 10,000 unique visitors and serve about 500-600,000 pages per day, using about 8GB per day of data transfer, and the database is about 3GB now. We're on a dual P4 with 3.06 GHz processors and dual ATA hard drives (with mysql on the second drive). And we have 1GB of RAM.

Apache has been blowing up a few times per hour during peak traffic times, and I'm positive it's a memory issue. While in top via ssh, I can tell when it's happening. I see the the free mem steadily shrink, along with the buffer; the buff steadily shrinks from about 15MB to 4MB's as the load average steadily climbs, and if I don't manually stop and then start apache, the load average blows up from around 2 something to over 10 within a single minute. Once it gets above 4, I have to move fast or it's all over.

During low traffic times, I watch as the buff shrinks, but fortunately there aren't enough processes going on to drive up the load average. I have a cron job to stop and restart apache every hour, and during these low traffic times, after the restart, the buff starts to climb again. If it doesn't have a chance to climb over 14MB or so before a peak traffic wave hits, apache blows up faster.

So, I've decided to move to another server with more RAM. I'm going to a dual Xeon 2.4 with SCSI drives and 2GB of RAM. I'm told the SCSI drives handle disk memory better than the ATA drives, and I'm told that since my problem isn't with processing power, this server can do as well as the P4 3.06 for the time being; plus, I can upgrade the 2.4 processor to the xeon 3.2 later with relative ease. Does this sound reasonable? I'm not technically proficient enough to know if these guys know their stuff.

In the meantime, I've had outside help consulting on my httpd.conf, to help make things more tolerable for users while I wait to be able to migrate to the new server. I'd like opinions on the settings they've had me input, and if those sound all right for this limbo time and if they'd do on the newer server:

Timeout 50
KeepAlive Off
MinSpareServers 5
MaxSpareServers 20
StartServers 8
MaxClients 160
MaxRequestsPerChild 1000

We went back and forth on the KeepAlive thing, but in the end, it's off, because there is a notable difference. Apache *does* blow up faster with it kept On (MaxKeepAliveRequests was 150 and KeepAliveTimeout was 10), but now with it off and the above settings, I'm only having to manually stop and start apache once per hour at peak traffic (instead of multiple times), and the cron job still does it for me at the top of the hour. It's not ideal, but it might help me bide time until I can move.

Does anyone here have input about this?
Thanks!
Subscribe
  • Post a new comment

    Error

    Comments allowed for members only

    Anonymous comments are disabled in this journal

    default userpic

    Your IP address will be recorded 

  • 1 comment