EIGRP Metric Calculator - Classic and Wide Metrics, DUAL

EIGRP Metric Calculator (Classic and Wide Metrics)

Build a path hop by hop, then get the classic 32-bit EIGRP composite metric, the 64-bit wide metric (named mode) with its RIB metric, and a DUAL successor / feasible successor / variance check. Exact integer math per RFC 7868 and Cisco documentation.

1. Path builder (outgoing interfaces toward the destination)

Add one row per outgoing interface along the path, as you would see it in show interfaces. Bandwidth is the interface bandwidth value. Delay can be typed in microseconds (what show interfaces prints as DLY) or in tens of microseconds (what the delay interface command takes). Both are always shown.

2. K values and metric results

Defaults: K1=1, K2=0, K3=1, K4=0, K5=0, rib-scale 128. K values are 0-255 and must match on both neighbors or no adjacency forms. Load and reliability only matter when K2 or K5 is non-zero. K6 (wide metrics, jitter/energy) is not modeled: IOS does not populate those attributes, so K6 has no effect today.

3. DUAL helper: successor, feasible successors, variance

Enter each neighbor's Reported Distance (RD, the neighbor's own metric to the destination) and the link cost your router adds to reach it. Distance through the neighbor = RD + link cost. Use either all-classic or all-wide numbers.

The page address updates as you type, so you can bookmark or share the exact scenario.

What this EIGRP metric calculator does

EIGRP does not use a single cost per link like OSPF. It carries a vector of values (minimum bandwidth, total delay, load, reliability, MTU, hop count) and turns them into one composite metric with the K values. This calculator does that work for you: you build the path from its outgoing interfaces, and it shows the classic 32-bit metric used by classic-mode EIGRP, the 64-bit wide metric used by named mode, the RIB metric that appears in show ip route, and every intermediate value so you can check your own math for CCNP ENARSI or CCIE practice. The DUAL helper then takes several neighbors and tells you the Feasible Distance, the successor, the feasible successors and which paths a variance value would install.

How it works

Classic EIGRP metric calculation formula

RFC 7868 section 5.6.1 and the Cisco metric weights documentation give the classic composite metric as:

metric = 256 * ( K1*BW + (K2*BW)/(256 - LOAD) + K3*DELAY ) if K5 != 0: metric = metric * K5 / (REL + K4) BW = 10^7 / minimum bandwidth on the path (kbps), truncated DELAY = sum of outgoing interface delays, in tens of microseconds
  • With the default K values (K1=1, K2=0, K3=1, K4=0, K5=0) it reduces to 256 * (10^7 / BWmin + sum of delays).
  • RFC 7868 says to truncate the bandwidth before applying the 256 scaling factor. The calculator does all math with exact integers (BigInt) and truncates every division, as integer router code does.
  • Load and reliability are fractions of 255 (255/255 = 100 % reliable, 1/255 = idle). On the path, load is the maximum and reliability is the minimum.
  • The metric is a 32-bit value. 4,294,967,295 (0xFFFFFFFF) means unreachable.

Microseconds or tens of microseconds?

This trips up many people. show interfaces prints the delay in microseconds (GigabitEthernet: DLY 10 usec). The delay interface command and the metric formula use tens of microseconds, so 10 usec becomes 1 and a T1 with 20000 usec becomes 2000. The path builder accepts either unit and always shows both.

Wide metrics (named mode)

RFC 7868 sections 5.6.2.2 to 5.6.2.5 and the Cisco EIGRP Wide Metrics guide define the 64-bit metric with EIGRP_BANDWIDTH = 10,000,000, EIGRP_DELAY_PICO = 1,000,000 and EIGRP_WIDE_SCALE = 65536:

Throughput = 10^7 * 65536 / minimum bandwidth (kbps) Latency = total delay (picoseconds) * 65536 / 10^6 metric = ( K1*Throughput + (K2*Throughput)/(256 - LOAD) + K3*Latency + K6*ExtAttr ) * K5/(K4 + REL) [K5 part only if K5 != 0] RIB metric = metric / rib-scale (rib-scale 1-255, default 128; capped at 4,294,967,295)

Delay is kept in picoseconds. A configured delay of N tens of microseconds is N x 10,000,000 ps. For interfaces faster than 1 Gbps that use their default delay, RFC 7868 (section 5.6.1.2) lists a wide delay that shrinks with speed: 1000 ns for 10 Gbps, 100 ns for 100 Gbps. That equals 10^13 / bandwidth in kbps picoseconds, and the calculator applies that rule. The same rule explains the IOS output for a loopback (8 Gbps): Total delay is 1250000 picoseconds. If you configure delay on such an interface, tick the "Delay set manually" box and the configured value is used instead.

Why wide metrics fix the problem above 1 Gbps

In the classic formula, 10^7 / 10,000,000 kbps is 1 for 10 Gbps, and every link faster than 10 Gbps truncates to 0. The smallest configurable delay is 10 usec, so delay can't tell them apart either. A 10G, 40G and 100G path can then look the same, which Cisco documents as the reason for "undesirable equal-cost load balancing". Wide metrics multiply by 65536 and count delay in picoseconds: 10 Gbps gives a throughput of 65,536, 100 Gbps gives 6,553. Links stay distinguishable up to about 4.2 Tbps. Because the Cisco RIB only stores 32 bits, the 64-bit result is divided by metric rib-scale before it is installed.

DUAL: successor, feasible successor and variance

  • Reported Distance (RD): the neighbor's own metric to the destination, as it advertises it.
  • Feasible Distance (FD): the lowest known total metric to the destination (RD + cost of the link to that neighbor).
  • Successor: the neighbor (or neighbors, on a tie) giving the FD.
  • Feasibility condition: a neighbor is a feasible successor only if its RD is strictly lower than the FD. An RD equal to the FD fails. This is what guarantees a loop-free backup path.
  • Variance (1-128, default 1): Cisco installs extra paths whose metric is within variance x FD, but only if they are feasible successors. Cisco's tech note says "less than" in one sentence and "less than or equal to" in its example. The calculator includes paths exactly at the limit. Up to maximum-paths routes are installed (4 by default).

The helper uses RD + link cost, which is exact for delay-style additions. A real router recomputes the composite metric from the vector (minimum bandwidth and summed delay), so if your link becomes the new minimum bandwidth on the path, use the path builder to get the real distance.

Sources

Vendor note: EIGRP is a Cisco protocol (RFC 7868 is an informational RFC written by Cisco), so all formulas here follow Cisco IOS / IOS XE. Neither RFC 7868 nor Cisco documents the exact rounding order when K2, K4 or K5 are non-zero. This calculator multiplies before it divides and truncates once per division, so real routers may differ by a few units in those non-default cases. With the default K values the results are exact.

Worked examples

  1. Cisco's own example. A 128 kbps link with a total delay of 84,000 usec: BW = 10^7 / 128 = 78,125, DLY = 8,400 tens of usec, metric = 256 x (78,125 + 8,400) = 22,150,400.
  2. Directly connected GigabitEthernet. Classic: 256 x (10 + 1) = 2,816. Wide: throughput 10^7 x 65536 / 1,000,000 = 655,360, latency 10,000,000 ps x 65536 / 10^6 = 655,360, composite 1,310,720, RIB metric 1,310,720 / 128 = 10,240. These are the values IOS shows for a connected Gigabit route.
  3. Loopback interface (8 Gbps, DLY 5000 usec). Classic: 256 x (1 + 500) = 128,256. Wide: throughput 81,920, latency 1,250,000 ps x 65536 / 10^6 = 81,920, composite 163,840. If you configure delay 500 on the loopback, the wide delay becomes 5,000,000,000 ps and the composite jumps to 327,761,920.
  4. Two GigabitEthernet hops to a remote loopback (named mode). Total delay 10,000,000 + 10,000,000 + 1,250,000 = 21,250,000 ps, latency 1,392,640, throughput 655,360, composite 2,048,000, RIB metric 16,000. This matches FD is 2048000, RIB is 16000 in a real topology table.
  5. The default example above (10G, 1G and FastEthernet). Minimum bandwidth 100,000 kbps, delay 10 + 10 + 100 = 120 usec. Classic: 256 x (100 + 12) = 28,672. Wide: 6,553,600 + trunc(111,000,000 x 65536 / 10^6) = 6,553,600 + 7,274,496 = 13,828,096, RIB metric 108,032. In wide mode the 10G hop adds only 1,000,000 ps instead of 10 usec.
  6. Variance (the default DUAL example, from Cisco's tech note). Paths through C, B and D cost 20, 30 and 45, and D reports RD 25. FD = 20 through C. B (RD 10) is a feasible successor, while D (RD 25, not below 20) is not. With variance 2 the limit is 40, so C and B share the traffic. Even variance 3 would not add D, because D fails the feasibility condition.

Reference: default bandwidth and delay per interface type

Values from the RFC 7868 Cisco compatibility table (section 5.6.1.2) and the Cisco loopback default, with the single-hop metrics this calculator gives (default K values, rib-scale 128).

InterfaceBW (kbps)DLY (usec)DLY (tens of usec)Wide delay (ps)Classic metricWide metricRIB (/128)
Tunnel (legacy)9500,00050,000500,000,000,000297,244,416105,585,777,777824,888,888
Serial 56 kbps5620,0002,00020,000,000,00046,226,17613,013,577,142101,668,571
DS0 64 kbps6420,0002,00020,000,000,00040,512,00011,550,720,00090,240,000
Serial T11,54420,0002,00020,000,000,0002,169,8561,735,175,95813,556,062
Serial E12,04820,0002,00020,000,000,0001,761,7921,630,720,00012,740,000
Ethernet 10M10,0001,0001001,000,000,000281,600131,072,0001,024,000
FastEthernet 100M100,00010010100,000,00028,16013,107,200102,400
ATM 155M155,00010010100,000,00018,94410,781,72984,232
GigabitEthernet 1G1,000,00010110,000,0002,8161,310,72010,240
2 Gbps2,000,0001015,000,0001,536655,3605,120
5 Gbps5,000,0001012,000,000768262,1442,048
10 Gbps10,000,0001011,000,000512131,0721,024
20 Gbps20,000,000101500,00025665,536512
25 Gbps25,000,000101400,00025652,428409
40 Gbps40,000,000101250,00025632,768256
50 Gbps50,000,000101200,00025626,214204
100 Gbps100,000,000101100,00025613,106102
400 Gbps400,000,00010125,0002563,27625
Loopback8,000,0005,0005001,250,000128,256163,8401,280

FAQ

How is the EIGRP metric calculated?

With the default K values the classic metric is 256 x (10^7 / slowest bandwidth in kbps + sum of delays in tens of microseconds). The bandwidth term is truncated to an integer before scaling. In named mode the wide metric is 10^7 x 65536 / slowest bandwidth plus total delay in picoseconds x 65536 / 10^6.

Is EIGRP delay in microseconds or tens of microseconds?

Both are used. show interfaces displays DLY in microseconds, while the delay interface command and the classic metric formula use tens of microseconds, so DLY 20000 usec on a T1 counts as 2000. Wide metrics convert the delay to picoseconds.

What are the default EIGRP K values?

K1=1, K2=0, K3=1, K4=0 and K5=0, plus K6=0 for wide metrics. By default only bandwidth and delay count. The K values must match on both neighbors, otherwise the adjacency does not come up.

What is the EIGRP RIB scale?

Wide metrics are 64-bit, but the Cisco routing table stores a 32-bit metric. EIGRP divides the wide metric by metric rib-scale (1-255, default 128) before installing the route, so a connected GigabitEthernet route with wide metric 1310720 shows up as 10240 in show ip route.

Why does EIGRP need wide metrics for 10 Gbps and faster links?

In the classic formula 10^7 / bandwidth is 1 for 10 Gbps and 0 for anything faster, and the smallest delay is 10 microseconds, so 10G, 40G and 100G paths can get identical metrics. Wide metrics scale by 65536 and count delay in picoseconds, which keeps links up to about 4.2 Tbps apart.

What is the difference between Feasible Distance and Reported Distance?

Reported Distance is the metric a neighbor advertises for the destination. Feasible Distance is the best total metric this router knows: the Reported Distance plus the cost of the link to that neighbor. A neighbor is a feasible successor only if its Reported Distance is strictly lower than the Feasible Distance.

Does variance let EIGRP use any slower path?

No. Variance n installs extra paths whose metric is within n times the best metric, but only if they are feasible successors. A path that fails the feasibility condition is never used for load sharing, whatever the variance.

Related tools

Comments

Popular posts from this blog

BGP Neighbor States

Reason legend in show ip ospf statistics

Cisco SPAN Port Mirroring: Practical Guide for Troubleshooting