If you’ve ever had a website or application crash on you when you’re in the middle of, say, online shopping, then you’ve seen how improper workload management can negatively impact users.
Within company IT infrastructure, if too many users try to access the same data or software at the same time, this can also cause a crash if the traffic isn’t properly balanced. How do companies achieve that balance? Enter load balancing.
Load balancing is how request processing stays fluid and functional.
Load balancing is the distribution of traffic or workload across multiple processing resources (for example, application servers or CPUs).
Load balancing devices called load balancers use either native or installed load balancing software to distribute traffic or workloads across processing resources with the goal of creating a more optimized end-user experience. Think of a load balancer as the access gate that determines how data gets to a company’s servers.
There’s no one right way to balance a workload, but each type does present certain advantages and disadvantages. Examples of load balancing methods include random assignment, round robin, source IP has and least connection.
By far the least organized of all the load balancing methods, random assignment does exactly what it says: It randomly assigns each workload to a server in a group of servers (server pool).
The theory behind random assignment sounds more complicated than it is. In probability theory, the Law of Large Numbers says that as a sample size grows, the median (middle) result in a sample set will eventually match the mean (average) result. Applied here, it means that the more times a workload is randomly assigned to a server within the pool, eventually every server in the pool will be handling approximately equal workloads even though the workloads may initially be unequal.
Of course, there are a few obvious, but conquerable, issues here:
The first of the more organized load balancing methods, round robin functions a lot like the game tournament style of the same name. Each server in a server pool is assigned a spot in the overall order of use, and each time new traffic comes in, it goes to the next server on the list.
Round robin distribution ensures each server can address incoming traffic. Issues arise, though, when length or processing demand of connections are taken into account. When long connections, or connections that have significant traffic flowing through them, start stacking up on a server, some servers can end up with much higher traffic than others, despite servers being given equal connections.
IP hashing works to distribute workload based on the incoming IP address of a server request, making it much more sophisticated than the previously mentioned methods. An incoming workload is algorithmically assigned a hash key based on its source IP address and destination, which is then used to assign a server to handle the incoming workload.
IP hashing can be an incredibly efficient way of handling incoming traffic, but there is a catch: What if there’s a ton of traffic coming from the same IP address? This can result in an overload on a single server. Overcoming this issue would involve setting capacity rules for either the number of connections on a single server from a single source, or on how many connections from a single source are allowed.
In a similar class to source IP hashing, the least connection method focuses its load balancing efforts on distributing traffic to the servers that currently have the fewest active connections. The idea is that any one server in the server pool should never end up with a significantly higher number of active connections than any other.
While this method does have issues with longer traffic connection times stacking up on a single server, it also, by design, deals with this issue better than other methods. Even with longer or more demanding sessions stacked up on a server, the server will never hit a significantly higher user count than any other server, which helps contain the demand issue.
Load balancing serve an additional business use as an extra security measure. By balancing out heavy incoming workloads, they improve resilience to direct denial of service (DDoS) attacks. By including cloud offloading with load balancing solutions, DDoS attacks become further ineffective, as the attack is shrugged away from a company’s servers into a public cloud.
Now, see how load balancing can impact one of the hottest topics in IT. Learn about cloud computing and why it's a big deal.
Zack is a former G2 senior research analyst for IT and development software. He leveraged years of national and international vendor relations experience, working with software vendors of all markets and regions to improve product and market representation on G2, as well as built better cross-company relationships. Using authenticated review data, he analyzed product and competitor data to find trends in buyer/user preferences around software implementation, support, and functionality. This data enabled thought leadership initiatives around topics such as cloud infrastructure, monitoring, backup, and ITSM.
Subscribe to keep your fingers on the tech pulse.