Overview
Dynamic routing protocols exchange reachability automatically. CCNA compares distance vector vs link state, administrative distance, and when to choose static vs dynamic routing.
Why routing protocols matter
Routers forward packets using the routing information base (RIB) — the routing table. Routes enter that table from three sources: connected interfaces, static configuration, and dynamic routing protocols. CCNA expects you to explain when each fits, how protocols differ, and how Cisco picks a winner when multiple sources disagree.
Routed vs routing: A routed protocol (IPv4/IPv6) carries user data. A routing protocol (OSPF, EIGRP, etc.) is the control-plane mechanism routers use to exchange reachability information and populate the RIB.
Static routing
Static routes are manually configured. There is no protocol overhead, but every topology change requires manual updates — fine for stub sites, not for large dynamic networks.
Syntax:
ip route [network] [mask] [next-hop | exit-interface] [admin-distance]
Default route (gateway of last resort):
ip route 0.0.0.0 0.0.0.0 203.0.113.1
A default route is a candidate default — the router uses it only when no more-specific prefix matches the destination.
Return-path requirement: If R1 has a static route to R3's subnet via R2, R3 must have a route back to R1's subnet (static or dynamic). One-way routing produces successful forward pings from one direction only.
! R1 is on 192.168.2.0/24 with R2 at 192.168.2.2 ip route 192.168.3.0 255.255.255.0 192.168.2.2
! R3 returns traffic via R2 at 192.168.3.1 ip route 192.168.1.0 255.255.255.0 192.168.3.1
Floating static: A backup static route with a higher administrative distance than the primary. It sits unused until the primary disappears.
ip route 10.10.10.0 255.255.255.0 10.10.20.2 5
AD 5 is higher than connected (0) or OSPF (110) defaults — used only when the primary path fails.
On multi-access Ethernet, prefer next-hop IP over exit-interface-only static routes so the router can ARP for the next hop. Point-to-point serial links may use exit interface alone.
Dynamic routing protocols
Dynamic protocols automatically adapt to topology changes. Routers exchange updates, learn new networks, and maintain routes without per-change manual edits — at the cost of CPU, memory, and bandwidth for protocol traffic.
| Protocol | Type | Metric | AD (internal) | Notes |
|---|---|---|---|---|
| Connected | — | — | 0 | Automatic when interface up/up |
| Static | — | — | 1 (default) | Admin-defined |
| OSPF | Link state | Cost (bandwidth) | 110 | Open standard IGP |
| EIGRP | Advanced DV | Composite (BW + delay) | 90 | Cisco proprietary (CCNA scope) |
| RIP | Distance vector | Hop count | 120 | Legacy awareness |
| External EIGRP | — | — | 170 | External routes |
| BGP (external) | Path vector | Attributes | 20 (eBGP) / 200 (iBGP) | Between ASes |

Administrative distance — lower is more trusted when multiple protocols offer the same prefix.
From study charts · jdepew88 CCNA notes

Protocol comparison — metric type, convergence, and scalability.
From study charts · jdepew88 CCNA notes
Distance vector vs link state vs hybrid
Distance vector — "routing by rumor." Routers advertise vectors of distance (metric) and direction (next hop) to neighbors. Limited visibility beyond adjacent routers.
- Metric example: RIP hop count (max 15 usable hops)
- Loop prevention: split horizon, poison reverse, triggered updates
- Bellman-Ford algorithm
- Easy to configure; poor scalability
Link state — Each router describes its local links and their state, floods LSAs, and every router builds an identical link-state database (LSDB) for the area. Each router runs SPF (Dijkstra) independently to compute best paths.
- Metric example: OSPF cost = reference bandwidth ÷ interface bandwidth
- Full topology visibility within the area
- More CPU/RAM (neighbor table, LSDB, routing table)
- Hierarchical design with Area 0 backbone when scaling beyond single area
Advanced distance vector (EIGRP) — Hybrid behavior: initial full table exchange like DV, but maintains a topology table, uses DUAL for loop-free backup paths, and sends incremental updates. Cisco proprietary; AD 90.
Do not confuse administrative distance with longest-prefix match. When RIPv2 offers 10.1.1.0/27 and OSPF offers 10.0.0.0/8, the longest match (/27) wins — AD only breaks ties for the same prefix length.
Classful vs classless
| Classful | Classless | |
|---|---|---|
| Subnet mask in updates | No | Yes |
| VLSM support | No | Yes |
| Example protocols | RIPv1, IGRP | RIPv2, OSPF, EIGRP |
| Summarization | Automatic at class boundaries | Manual / at ABR (OSPF) or interface (EIGRP) |
Modern CCNA labs assume classless protocols with explicit masks.
Autonomous systems
An autonomous system (AS) is a group of networks under one administrative domain. IGPs (OSPF, EIGRP, RIP) operate within an AS. EGPs (BGP) connect between ASes.
- AS number: Public (registered for Internet BGP) or private (64512–65534)
- Example: ISP AS 1 peers via BGP with ISP AS 2; each may run OSPF internally
Reading show ip route
Every route line tells you how it was learned, AD/metric, and forwarding action.
S 192.168.3.0/24 [1/0] via 192.168.2.2
S= static[1/0]= AD 1, metric 0via 192.168.2.2= next-hop
O 10.1.0.0/16 [110/20] via 192.168.1.2, 00:05:00, GigabitEthernet0/1
O= OSPF intra-area[110/20]= AD 110, OSPF cost 20
Gateway of last resort is 203.0.113.1 to network 0.0.0.0
S* 0.0.0.0/0 [1/0] via 203.0.113.1
S*= static default route candidate
show ip route show ip route connected show ip route static show ip route ospf show ip route summary show ip protocols show ip interface brief
IGP selection (exam framing)
| Scenario | Typical choice |
|---|---|
| Stub branch, single WAN link | Default static to HQ |
| Single vendor enterprise, fast convergence | EIGRP |
| Multi-vendor, hierarchical areas | OSPF |
| Small lab / legacy mention | RIPv2 |
CCNA does not ask you to design ISP BGP — know that BGP is between ASes and uses path attributes, not simple metric.
Troubleshooting checklist
| Symptom | Check |
|---|---|
| Remote subnet unreachable | show ip route — is prefix present? |
| Route in table but traffic fails | Next-hop reachable? ARP? ACL? |
| Wrong path chosen | Longest match first, then AD for ties |
| Static works one direction only | Return route on far router |
| Default route missing | 0.0.0.0/0 or ip default-network context |
Ping the next-hop at each hop before blaming the final destination.
Exam checklist
You do not configure static routes for subnets directly attached to an up/up interface — they appear as C routes with AD 0.
Administrative distance compares route sources (OSPF vs static). Metric compares paths within the same protocol (two OSPF paths — lower cost wins).
OSPF process ID (1–65535) is locally significant — neighbors need not match. EIGRP AS number must match on all peering routers.
Quick review
- Static = request manual maintenance; default routes send unknown destinations to a gateway of last resort
- Distance vector = neighbor rumors; link state = shared topology map + SPF
- Lower AD is more trusted when the same prefix length is advertised by multiple sources
- Longest-prefix match always beats a shorter prefix regardless of AD
show ip routecodes:Cconnected,Sstatic,OOSPF,DEIGRP,*default candidate