Load Balancing Your Web Site
Practical Approaches for Distributing HTTP Traffic
By Ralf S. Engelschall
When it comes to handling lots of visitors, high-volume sites like Yahoo!, Netscape, and Microsoft have learned that the actual quality of service a Web server provides to end users typically depends on two parameters -- network-transfer speed and server-response time. Network-transfer speed is mainly a matter of your Internet-link bandwidth, while server-response time depends upon resources: fast CPU (especially for CGI programs), lots of RAM (especially for parallel-running HTTP daemon processes), and good I/O performance (especially for disk and network traffic).
What do you do when these resources are exhausted and your Web server is struggling against heavy traffic? You could install more RAM on existing machines, or perhaps replace the CPU with a faster one. You could also use faster or dedicated SCSI controllers and disks with shorter access times (perhaps a RAID system with a huge cache). Software could be tuned as well; you could adjust operating-system parameters and Web-server software to achieve better performance.
Or you can address the problem with an alternative approach: Improve performance by increasing the number of Web servers. This involves an attempt to distribute the traffic onto a cluster of back-end Web servers. Aside from the technical hurdles, this is an interesting approach, because the back-end servers don't need to be large-scale machines -- medium-scale hardware works just fine.
Assume there are N back-end servers available, named wwwX.f