Sub topic 19
EIGRP and DUAL: an advanced distance-vector design
This chapter assumes you know the Bellman-Ford update, count to infinity, and the loop-prevention techniques from the earlier chapters. It also assumes you can read a routing table. EIGRP (Enhanced Interior Gateway Routing Protocol) is a distance-vector protocol that avoids routing loops by proof instead of by timers.
Where EIGRP sits
EIGRP began as a Cisco protocol. Cisco documented it in RFC 7868 as informational, not as a standard. It still behaves like a distance-vector protocol. A router learns routes from neighbors, never sees the full topology, and passes on its own best answers. It differs from RIP in five ways:
- It sends no periodic full-table updates. Routers send partial updates, and only when something changes.
- It finds neighbors with hello packets sent to multicast 224.0.0.10. It runs directly over IP protocol 88.
- It delivers updates reliably with its own acknowledgment mechanism, so it does not rely on periodic repetition.
- Its metric is composite, not a hop count.
- It uses the Diffusing Update Algorithm (DUAL) to keep every route loop-free at every instant.
The metric
By default, the classic EIGRP metric uses only bandwidth and delay (constants K1 and K3 are 1, the others 0):
metric = 256 × (10^7 / lowest bandwidth in kbps along the path + sum of delays in tens of microseconds)
The lowest bandwidth on the path matters, not the sum. Delay accumulates hop by hop. Routers must agree on the K values to form a neighbor relationship. A mismatch is a common reason neighbors never come up.
DUAL vocabulary
DUAL tracks two numbers for each destination, and the difference between them is the core of the protocol.
| Term | Meaning |
|---|---|
| Feasible distance (FD) | The best total metric from this router to the destination. |
| Reported distance (RD) | A neighbor's own metric to the destination, as the neighbor advertises it. Also called advertised distance. |
| Successor | The neighbor that gives the lowest total metric. It is the next hop installed in the routing table. |
| Feasible successor | A backup neighbor that satisfies the feasibility condition. |
| Passive state | The route is stable and has a successor. |
| Active state | The route has no usable successor, and the router is querying neighbors. |
The feasibility condition
A neighbor is a feasible successor if its reported distance is strictly less than the router's current feasible distance:
RD(neighbor) < FD
The reasoning is a loop-freedom argument. If the neighbor is closer to the destination than I have ever been, its path cannot pass through me. If it did, its distance would include my distance and would be larger than my FD. Such a neighbor is therefore a safe backup, and no recomputation is needed to use it.
A worked example
Router R reaches destination N through three neighbors. Each row gives the link cost from R to the neighbor and the neighbor's reported distance to N.
| Neighbor | Link cost | RD | Total | Role |
|---|---|---|---|---|
| A | 10 | 10 | 20 | Successor, FD = 20 |
| B | 10 | 15 | 25 | Feasible successor (15 < 20) |
| C | 5 | 25 | 30 | Not feasible (25 is not below 20) |
C's total is lower than a plain "backup" might suggest, yet it is not feasible. Its path might run back through R, and R cannot tell without asking.
def classify(neighbors):
"""neighbors: name -> (link_cost, reported_distance).
Returns (successor, feasible_distance, feasible_successors)."""
totals = {n: link + rd for n, (link, rd) in neighbors.items()}
successor = min(totals, key=totals.get)
fd = totals[successor]
feasible = [
n for n, (link, rd) in neighbors.items()
if n != successor and rd < fd
]
return successor, fd, feasible
print(classify({"A": (10, 10), "B": (10, 15), "C": (5, 25)}))This prints ('A', 20, ['B']). The sketch ignores ties. Real EIGRP installs several equal-cost successors, and it can also balance traffic across unequal paths using the variance setting.
What happens when a route fails
The reaction depends on whether a feasible successor exists.
With a feasible successor, the switch is a local table lookup. No packets are exchanged before traffic moves, so recovery is nearly instant. Without one, the router enters the active state and sends a query to each neighbor. A neighbor with a valid route replies. A neighbor without one may query its own neighbors in turn. The computation spreads outward, which is the "diffusing" in the algorithm's name. Because every router joins the computation only when its own successor is affected, loops cannot form during it.
Failure modes and design limits
- Stuck in active (SIA). The active router waits for every reply. If a neighbor never answers, because of a congested link or a distant router that is still querying, the route stays active until the active timer expires (three minutes by default). The router then resets that neighbor relationship, which can cause a wider disruption. Newer implementations send SIA queries and replies so a busy but healthy neighbor can say it is still working.
- Query scope. Queries travel until they hit a router that has an answer or a boundary. Route summarization and stub routers (which are not asked about routes they could only reach through someone else) limit how far a query spreads.
- A conservative condition. The feasibility condition can reject a neighbor whose path is actually loop-free, as C in the example might be. The cost is an extra query when it matters. The benefit is that no unsafe path is ever used.
- Mismatched parameters. Different K values or autonomous system numbers prevent neighbors from forming.
Configuration
router eigrp 100
network 10.0.0.0 0.0.0.255
no auto-summaryThe number 100 is the autonomous system number, and it must match on neighbors. The network statement selects the interfaces that run EIGRP. Recent Cisco software also offers a "named mode" syntax. The behavior is the same.
Comparison with RIP and OSPF
RIP prevents loops with heuristics (split horizon, hold-down, maximum metric) and still converges slowly. OSPF prevents loops because every router computes from the same database. EIGRP gets loop-free behavior without a global map, and it converges quickly when a feasible successor exists. Its costs are a more complex state machine, a reliance on query propagation in the worst case, and a history of vendor-specific support.
Exercise
Router R has neighbors X (link cost 4, RD 6), Y (link cost 2, RD 9), and Z (link cost 8, RD 12). Which neighbor is the successor, what is the FD, and which neighbors are feasible successors? What happens if the successor fails?
Show answer
The totals are X = 10, Y = 11, and Z = 20, so X is the successor and FD = 10. A feasible successor needs RD < 10. Y has RD 9, so it qualifies. Z has RD 12, so it does not. If X fails, R installs Y immediately with a new FD of 11 and stays passive. If both X and Y failed, R would go active and query its neighbors, including Z.