Load Balancing and Load Balancer
This article describes load balancing basics and mentions load balancer types. Load balancing is the method used to balance the load. Load balancers are used to perform load balancing. The load balancer consists of hardware, software or combination of both. Load can be tasks, web traffic, applications etc.
Why Load Balancing is needed?
Due to following reasons load balancing is needed:
• To scale up the applications or services.
• To perform easy maintenance and administration. This is possible with the help of multiple backup servers available for the same kind of job.
• Resource sharing: Can offload the heavy traffic on multiple servers connected on the different ports. This is applicable to one website receiving more traffic from web. Due to this, same copies of webpages are stored on multiple servers and these servers are used to balance the web page requests. The job of balancing is done by device called load balancer.
• Pipelining:The concept is applied to tasks performed by processor or CPU. If there are multiple tasks to be performed, rather than executing each one by one serially, tasks are performed simultaneously in parallel. This speeds up the operation of a computing device. Hence pipelining concept here acts as load balancer for a CPU.
• Load balancing is also applied to complex wireless receivers. Here algorithms are ported on DSP as well as FPGA, where in time critical tasks are performed by FPGA and less critical tasks are performed by DSP. In other words, layer-1 (Physical layer) algorithms are ported on FPGA while layer-2 and above functionalities are ported on DSP.
Load Balancer types
Load balancers are of different types based on the load to be balanced.
They work on following different load balancing algorithms:
➨Round Robin: The load balancer receives the requests and distribute evenly across group of servers connected physically with it.
➨Least Connections: The load balancer keeps record of number of client connections currently available with physical servers. Based on this information it routes new client request with the server having least connections.
➨Based on IP Address: The load balancer looks at the incoming IP packet and port and appropriately route the packet to the physical server.
The figure-1 above depicts typical setup used to balance the traffic load from the server.
As shown Server Load Balancer is used to evenly balance the load across the servers.
It does following to perform load balancing:
• It keeps information of the servers i.e. IP address/Port address.
• It houses protocols such as TCP/IP, UDP/IP, FTP, SIP etc. to perfom its job.
• It does Network Address Translation where in packets are re-written with new IP address and port number as they pass through load balancer.