Proxy choices: mod_proxy_balancer, nginx + proxy balancer, haproxy? Proxy choices: mod_proxy_balancer, nginx + proxy balancer, haproxy? apache apache

Proxy choices: mod_proxy_balancer, nginx + proxy balancer, haproxy?


Apache is a bit of a strange beast to use for your balancing. It's certainly capable but it's like using a tank to do the shopping.

Haproxy/Nginx are more specifically tailored for the job. You should get higher throughput and use fewer resources at the same time.


HAProxy offers a much richer set of features for load-balancing than mod_proxy_balancer, nginx, and pretty much any other software out there.

In particular for your situation, the log output is highly customisable so it should be much easier to identify when, where and why slow requests occur.

Also, there are a few different load distribution algorithms available, with nice automatic failover capabilities too.

37Signals have a post on Rails and HAProxy here (originally seen here).


if you want to avoid Apache, it is possible to deploy a Mongrel cluster with an alternative web server, such as nginx or lighttpd, and a load balancer of some variety such as Pound or a hardware-based solution.

Pounds (http://www.apsis.ch/pound/) worked well for me!