IPv6 OSPFv3 Routing
OSPFv3 for IPv6: what changed from OSPFv2, per-link configuration, the adjacency state machine, and configuring and verifying OSPFv3 on Cisco IOS.
1. Executive Summary & Objective
OSPFv3 is OSPF rebuilt for IPv6. The link-state algorithm, areas, LSAs, and the SPF calculation are conceptually the same as OSPFv2, but the configuration model and transport changed in ways that trip up engineers coming from IPv4.
Objective: Configure OSPFv3 per-interface on Cisco IOS, explain why it uses link-local addressing and still needs a router-id, and verify adjacencies using the neighbor state machine.
2. Core Concept & Theory (The βWhyβ)
What changed from OSPFv2 β OSPFv3:
| Aspect | OSPFv2 (IPv4) | OSPFv3 (IPv6) |
|---|---|---|
| Enabling | network statements under the process |
Per-interface ipv6 ospf PID area AREA |
| Transport | IPv4 | IPv6, over link-local source addresses |
| Adjacency/next-hop | Interface IPv4 address | Link-local (fe80::) |
| Addressing in protocol | Address + mask in LSAs | Topology decoupled from addressing (link LSAs) |
| Router-id | Auto from highest IP | 32-bit, must be set if no IPv4 |
| Authentication | Built-in (MD5) | Uses IPv6 IPsec (AH/ESP) |
3. Architecture & Topology (Visualizing)
A two-router backbone in area 0:
The adjacency state machine
Two OSPFv3 routers walk through these states to synchronise:
4. Command Execution & Deployment (The βHowβ)
ipv6 unicast-routing
!
interface GigabitEthernet0/0
ipv6 address 2001:db8:12::1/64
ipv6 ospf 1 area 0 ! enable OSPFv3 directly on the interface
!
interface Loopback0
ipv6 address 2001:db8:1::1/128
ipv6 ospf 1 area 0
!
ipv6 router ospf 1
router-id 1.1.1.1 ! MANDATORY on an IPv6-only router
5. Verification & Troubleshooting
show ipv6 ospf neighbor ! should reach FULL (or 2WAY for DROTHER pairs)
show ipv6 ospf interface brief ! area, cost, state, neighbor count
show ipv6 route ospf ! learned routes with fe80:: next-hops (via 'O')
| Symptom | Cause |
|---|---|
Neighbor stuck in INIT |
Hellos one-way β check an ACL or mismatched interface |
Neighbor stuck in EXSTART |
MTU mismatch between the two links |
| No adjacency at all | Mismatched area, or OSPFv3 not enabled on both interfaces |
| Process wonβt start | Missing router-id on an IPv6-only box |
6. Hands-on Lab
Bring up OSPFv3 area 0 on R1 and advertise a loopback.
Lab: OSPFv3 area 0
Enable IPv6 routing, set a router-id, and enable OSPFv3 on the transit and loopback interfaces.
Objectives
- Enable IPv6 routing globally.
- Create the OSPFv3 process.
- Set the mandatory 32-bit router-id.
- Select the transit link.
- Enable OSPFv3 on the interface in area 0.
7. Key Takeaways
- OSPFv3 is enabled per-interface (
ipv6 ospf PID area AREA), not with network statements. - Adjacencies and next-hops use link-local addresses.
- A 32-bit router-id is mandatory when thereβs no IPv4 to derive it from.
- The state machine (DownβInitβ2-WayβExStartβExchangeβLoadingβFull) is identical to OSPFv2 β
EXSTARThangs almost always mean an MTU mismatch.
π§ͺ Want to practise this on your own computer? See how to set up your lab →