Routing Fundamentals
This domain checks whether you can read a routing table and predict forwarding: longest match, administrative distance, metric, static versus dynamic routing, and the basic behaviour of RIP, OSPF, EIGRP and BGP.
Selection order
- Longest prefix match wins outright, regardless of AD or metric.
- Among routes to the same prefix, lowest administrative distance wins.
- Among equal AD and prefix, lowest metric wins. Default ADs: connected 0, static 1, eBGP 20, EIGRP 90, OSPF 110, RIP 120, iBGP 200.
Protocol profiles
- RIP: distance vector, hop count, maximum 15 hops (16 means unreachable), updates every 30 seconds, split horizon and route poisoning limit loops.
- OSPF: link-state, Dijkstra SPF, cost = reference bandwidth (default 100 Mbps) divided by interface bandwidth, so 1 Gbps and 10 Gbps both cost 1 unless auto-cost reference-bandwidth is raised. Areas, ABR/ASBR roles, DR/BDR election on broadcast segments.
- EIGRP: DUAL, composite metric built from bandwidth and delay, feasible successor gives an instant backup, AD 90 internal and 170 external.
- BGP: path vector between autonomous systems; AS_PATH and local preference drive selection; used for internet multihoming.
Static routes can specify a next hop, an exit interface or both (fully specified). A floating static sets a higher AD so it installs only when the primary route disappears.
Worked example
A router holds 0.0.0.0/0 via the ISP, 10.0.0.0/8 via R2, 10.1.0.0/16 via R3, and 10.1.2.0/24 learned by OSPF via R4, plus a floating static for 10.1.2.0/24 with AD 200. A packet to 10.1.2.55 matches /8, /16 and /24, so the /24 wins. Between the two /24 entries OSPF (110) beats the static (200), so traffic goes to R4 while OSPF is up. If OSPF fails, the static becomes the only /24 and installs. A packet to 10.9.9.9 matches only 10.0.0.0/8 and goes to R2, even though a default route exists.
Traps
- Believing "lowest AD wins" globally; a /24 with AD 120 beats a /8 with AD 1.
- Forgetting the default route applies only when no more specific route matches.
- Assuming OSPF cost reflects real bandwidth once links exceed 100 Mbps.
- Building a floating static with a lower AD than the primary, so it never floats.
- Designing RIP networks beyond 15 hops, where destinations appear unreachable.