EIGRP unequal-cost load balancing is one of those topics that we all try to run away from. EIGRP will not perform unequal cost load balancing by default and we have to use the variance command to do so. While working through IE’s vol 2 workbook, I came across a real nice lab that tested unequal cost load balancing. So I decided why not write a brief tutorial that might help others also.
Before we start getting into the configuration, let’s talk about how EIGRP inserts routes in the EIGRP topology table. EIGRP uses two metrics to perform all the calculations:
Advertised Distance (AD): This is the distance that is “advertised” by the upstream neighbor as their cost to the destination.
Feasible Distance (FD): Feasible distance is basically the sum of the Advertised Distance and the distance to the upstream neighbor from the local router.
Successor: Your local router will look through all the advertised paths to a destination and choose the path with the lowest Feasible Distance (FD). This path will have the lowest end-to-end metric and is called the successor. Successor is the best route to the destination.
Feasible Successor: These are paths that can be installed in the routing table if the successor is lost. For a path to be considered a feasible successor, it must satisfy the feasibility condition. A path’s Advertised Distance (AD) mst be lower than the Feasible Distance (FD) of the successor for it to be deemed a feasible successor.
Only routes that are feasible successors can be used for unequal cost load balancing in EIGRP. This is where variance command comes in.
FD of Feasible Successor <= FD of Successor x Variance
This is the only way a feasible successor will be installed in the routing table.
Let’s look at an example regarding unequal cost load balancing. Our goal is to perform unequal cost loadbalancing at a ratio of 5:1 between the two paths. R1 has two paths to the 164.1.26.0/24 network in the above topology.
Path 1 – R1 > R3 > R2 > VLAN 26
Path 2 – R1 > R2 > VLAN 26
Path 2 – R1 > R2 > VLAN 26
By default, EIGRP will choose the path with the lowest metric. For this topology, the Point to point link between R1-R3 is 1.536 Mbps, frame-relay link between R2-R3 is 1.28 Mbps and the frame-relay link between R1-R2 is 256Kbps. In this scenario, R1 will choose Path 1 to reach VLAN 26. At this point if we configure the variance of 5, then the traffic will be load balanced between the two paths at a ratio of 80:23 as shown in the output below.
RSRack1R1#sh ip route 164.1.26.6Routing entry for 164.1.26.0/24Known via “eigrp 100″, distance 90, metric 3026432, type internalRedistributing via eigrp 100Last update from 164.1.12.2 on Serial0/0, 00:00:56 agoRouting Descriptor Blocks:* 164.1.13.3, from 164.1.13.3, 00:00:56 ago, via Serial0/1Route metric is 3026432, traffic share count is 80Total delay is 40100 microseconds, minimum bandwidth is 1280 KbitReliability 255/255, minimum MTU 1500 bytesLoading 1/255, Hops 2164.1.12.2, from 164.1.12.2, 00:00:56 ago, via Serial0/0Route metric is 10514432, traffic share count is 23Total delay is 20100 microseconds, minimum bandwidth is 256 KbitReliability 255/255, minimum MTU 1500 bytesLoading 1/255, Hops 1
To achieve a 5:1 ratio, we can modify the metric through R2 to be 5 times the metric through R3. But before we can do that, let’s figure out how the metric is being calculated in the first place.
Metric = [K1*BW+(K2*BW)/256-Load)+K3*Delay]*[K5/(Reliability+K4)]
As we know, by default K1 and K3 equals 1 while all the other values are ZERO. So we can modify the above equation as follows:
Metric_R3 = (10^7/BW+Delay/10)*256
Metric_R3 = (10^7/1280+40100/10)*256
Metric_R3 = 3026432
In order to get the 5:1 ratio, we must increase the metric through R2 to be 5 times that of the metric through R3. This is how we can get the value of the DELAY through R2.
Metric_R2 = Metric_R3 * 5
(10^7/BW+Delay/10)*256 = (10^7/BW+Delay/10)*256*5
(10^7/256+Delay/10) = (10^7/1280+40100/10)*5
(39062.5+Delay/10 = (7812.5 + 4010) * 5
Delay/10 = 59112.5 – 39062.5
Delay = 20050 * 10
Delay = 200500
Looking through the routing table, we can see that we already have a delay of 100 microseconds to reach VLAN26.
RSRack1R2#sh ip eigrp topology 164.1.26.0 255.255.255.0IP-EIGRP (AS 100): Topology entry for 164.1.26.0/24State is Passive, Query origin flag is 1, 1 Successor(s), FD is 28160Routing Descriptor Blocks:0.0.0.0 (FastEthernet0/0), from Connected, Send flag is 0×0Composite metric is (28160/0), Route is InternalVector metric:Minimum bandwidth is 100000 KbitTotal delay is 100 microsecondsReliability is 255/255Load is 1/255Minimum MTU is 1500Hop count is 0
So R1′s local delay to R2 should be (200500 - 100 or 20040 tens of microseconds. Once we configure the delay of 20040 on R1′s Serial interface, we should be able to achieve the 5:1 ratio.
RSRack1R1#sh ip route 164.1.26.6Routing entry for 164.1.26.0/24Known via “eigrp 100″, distance 90, metric 3026432, type internalRedistributing via eigrp 100Last update from 164.1.12.2 on Serial0/0, 00:00:05 agoRouting Descriptor Blocks:* 164.1.13.3, from 164.1.13.3, 00:00:05 ago, via Serial0/1Route metric is 3026432, traffic share count is 5Total delay is 40100 microseconds, minimum bandwidth is 1280 KbitReliability 255/255, minimum MTU 1500 bytesLoading 1/255, Hops 2164.1.12.2, from 164.1.12.2, 00:00:05 ago, via Serial0/0Route metric is 15132160, traffic share count is 1Total delay is 200500 microseconds, minimum bandwidth is 256 KbitReliability 255/255, minimum MTU 1500 bytesLoading 1/255, Hops 1
Using delay is one of the methods of achieving unqual cost loadbalancing. I hope this tutorial has been helpful to you. Don’t forget to leave comments.