Goodbye Apache, Hello Nginx

Yesterday I noticed that a few times throughout the day my site was unreachable, and when I logged in to the server I noticed that there were hundreds of apache threads running as well as abnormally high memory and cpu usage… enough to the point where the server was almost unusable.I decided it was time to get off all the old software and do home housekeeping.


The site was running on Apache 2 dot something with PHP5 and Mysql 5.1; this all ran on top of Debian 6.0 which had been upgraded from Debian 5.0. For some reason the boot process was doing Grub 2, then Grub, then actually booting the OS… Can’t remember if I told it to install grub 2 or what. Overall it was just becoming pieced together and not streamlined.


Now the site runs on Nginx with PHP-FPM and Mysql 5.5; I also switched over to Ubuntu 12.10… still Debian based but will a little more up-to-date packages. Nginx is the same webserver and proxy platform that, Netflix, and almost 25% of the top 1000 websites use. It is pretty easy to configure and it scales much better than Apache. While I’m not that worried about it scaling I am hoping that it helps to avoid exploit scans and some of the security problems that Apache can leave open if not patched in a timely manner, remember I have a day job too :).

Backend Hardware

The hardware running my site has stayed the same; it includes two HP DL365 G1 servers (AMD Opteron 2200 series CPU) and an HP MSA1000 Fiber Channel SAN. The MSA is configured with 8x146GB 15k RPM drives in RAID 10 and a bunch of 72GB drives in RAID5. Of course the bare metal software is vSphere 5.1 running below all of the linux servers 🙂

Future hardware upgrade plans including moving the DL360 G5 servers from my home lab (after I find something to replace them with) to my colo site and possibly moving from the HP MSA1000 to a newer SAN platform or maybe to the HP or VMware Virtual SAN… depending on what is affordable.

I would like to thank all of my site sponsors for their continued support, without them all of the cash for this hardware would be coming directly out of the family check book.


Share This Post

One Response to "Goodbye Apache, Hello Nginx"

Post Comment