EIGRP For The CCNA: Unequal-Cost Load Balancing Lab
There are two things you must be aware of when using EIGRP unequal-cost load balancing, and we’ll cover those (and a whole lot more) in this lab.
In the previous lab, we saw equal-cost load balancing in action. Now it’s time to do a little unequal-cost balancing, using this network:
R1’s routing table shows EIGRP equal-cost load balancing in action. The metrics for the two available paths to 184.108.40.206 /27 are exactly the same, so both paths are in the routing table.
Checking R1’s EIGRP topology table, we note there are two entries for both 220.127.116.11 /24 and 18.104.22.168 /24. Each route has one successor and one feasible successor.
Our routing would be more efficient if we balanced the load from R1 to 22.214.171.124 /24 over those two available paths. The metrics of those two paths are so close (2297856 and 2300416) that it doesn’t make sense to leave one idle while letting the other path handle the full load for traffic heading for 126.96.36.199 /24.
That’s where EIGRP unequal-cost load balancing comes in. EIGRP runs equal-cost load balancing by default, but unequal-cost balancing requires a little configuration, a little math, and an eye for details and unexpected results. We’ll use all of those as we proceed with this lab.
One magic word enables unequal-cost load balancing in EIGRP. The variance command is a multiplier and has a default value of 1. Using variance is a two-step process:
- The router will multiple the Feasible Distance of the route by the variance value.
- Any feasible successor with a metric less than that new value will be entered into the routing table.
In print, I admit that sounds a little confusing, perhaps even a tad askew. Thankfully, the reality of this command is simple. Consider the two paths from R1 to R2’s loopback in the topology table.
The successor has a metric of 2297856. By setting the EIGRP variance to 2 on R1, any route to 188.8.131.52 /24 with a metric of less than 4595712 (2 x 2297856) will be entered into the EIGRP routing table and will participate in unequal-cost load sharing. The only feasible successor to that route has a metric of 2300416, so it certainly qualifies! Let’s run variance 2 on R1.
With unequal-cost load balancing enabled, R1’s EIGRP routing table now shows both the successor and feasible successor for 184.108.40.206 /24. Note that the actual metrics of the routes do not change.
The feasible successor and successor are also showing up for R3’s loopback network. This illustrates a very important point regarding variance, and you gotta watch out for it – it’s an all-or-nothing command. When you change variance, you’re changing it for your router’s entire EIGRP configuration. (That’s one of the important variance tips I mentioned at the top of the page. The second one’s coming up.)
You can verify the variance setting with our pal show ip protocols.
Note the maximum path value of 4. This value defines how many paths can be used for load balancing to a single destination. You can change the value from the default of 4 with the maximum-paths command, but if you set it to 1, you’re disabling load balancing!
Time for that second vital variance tip!
You might have looked at that lab and thought “Hey, I don’t need to do any math. I’ll just enter variance 255 and I’ll get all the load balancing I want!”
You also might just get load balancing you don’t want. Let’s say we have three valid paths to the same network. Path 1 has a metric of 5000, Path 2 a metric of 7000, and Path 3 a metric of 55000. That gives us two links with similar speeds and a third path that’s way out of line when compared to the other two. Do you really want to load balance over that third path? Probably not. It’s a good backup link, but not one I want to use in load balancing.
Bonus tip: With unequal-cost load balancing in effect, the load each link carries is proportional to the metric. If one path’s metric is twice as good as another, that path will carry roughly twice as much data.
Coming up next, a look at DUAL queries. You can also use these links to other EIGRP tutorials to get ready for success on your CCNA and CCNP exams:
EIGRP Adjacencies — Building & Troubleshooting