.Dd 2005-05-25 .Dt fair 7 .Os "Debian GNU/Linux" .\" $Id: fair.7 96 2005-05-31 17:02:37Z wsl $ .\" $URL: https://svn.fair.uvt.nl/branches/0.5/doc/fair.7 $ .Sh NAME .Nm fair .Nd simple TCP load balancing service .Sh DESCRIPTION .Nm is a load balancer for TCP connections. It can be used to distribute incoming connections for SMTP, HTTP or any other TCP service to multiple hosts, distributing the load as evenly as possible. .Pp .Nm consists of two daemons. The .Nm carrousel is the front-end; it keeps track of back-end hosts and their status, and forwards incoming connections to the back-ends in such a way that the load is distributed fairly. The .Nm transponder runs on the back-end hosts, it registers with the carrousel and sends it status information. The TCP connections forwarded by the .Nm carrousel are not sent to the .Nm transponder daemons but are sent directly to the desired service running on the back-end host. Both daemons share a single configuration file. .Sh EXAMPLES The following example shows how to set up .Nm to service HTTP connections and to distribute them over back-ends in the 192.168.1.0/24 subnet. .Pp The configuration file .Pa /etc/fair.conf contains the following: .Bd -literal -offset indent WorkerService = http BalancerService = http AllowUDP = ^192\.168\.1\.[0-9]+$ .Ed .Pp On .Pa www.example.com , the front-end server receiving the incoming HTTP connections, just run: .Bd -literal -offset indent carrousel .Ed .Pp On each of the back-ends run: .Bd -literal -offset indent transponder www.example.com .Ed .Sh SEE ALSO .Xr carrousel 8 , .Xr transponder 8 , .Xr fair.conf 5