Apache configuration
Recently I was advised to setup apache like this:
MinSpareServers 10
MaxSpareServers 15
MaxClients 150
MaxRequestsPerChild 1000
I was running with this configurations:
MinSpareServers 5
MaxSpareServers 10
MaxClients 100
MaxRequestsPerChild 500
Note that I'm in a 360 linode using ubuntu 8.10.
Why are the real differences?
Thanks
n
5 Replies
In other words, you'll be able to serve more simultaneous users, but you'll also use quite a bit more RAM. But do you really expect to serve 150 simultaneous users with Apache on a Linode 360? (That would be 43K unique visitors a day, if each visitor stayed on your site for 5 minutes on average.)
Figure out how much RAM you're using under peak load, and if it's too much, go back to the old config. Otherwise you won't notice a big difference unless you get dugg or slashdotted.
I switch back to my old configuration. Let's see if it stays lower.
Any configuration advice for a 360 linode?
@nfn:
Any configuration advice for a 360 linode?
Get rid of Apache and install a lightweight web server, such as lighttpd and nginx:P
Lighttpd has a very ugly configuration for virtual hosting
I used nginx, but since I need to expire images, js and css and there was no option to do it with file types, only extensions, some images that where rewritten from php where having some issues, so I lost may patience
header('Expires: ' . gmdate('D, d M Y H:i:s', time() + 86400) . ' GMT');
The example above will expire, after 86,400 seconds (24 hours), whatever file gets downloaded through the script. Adjust the interval according to your needs, and place it right before the line that sends the file – which is usually readfile() or sometimes fpassthru().
As for me, after having used lighttpd and nginx, I don't think I'll ever go back to bloated Apache.