I have a web server running on a virtual machine. It can’t handle a large load at all. It isn’t supposed to. I rarely get *that* much traffic to the site (http://luci.ics.uci.edu/blog) However, out of the box, or after an upgrade or something, apache2 came configured to handle way more clients than the ram could support. The machine was crashing… I couldn’t figure out why. It was spawning tons of “apache2″ processes. I figured that was probably part of the problem.
So after some digging I discovered this post on StackOverflow which clued me into the “MaxClients” setting in apache. I reduced this from 150 to 25 and so far the box is doing much better. It seems to be getting a lot of hits. Maybe something went semi-viral, but at least it’s staying up now.