How do you configure a static IPv6 route to a link-local next hop, and why do you need the interface?
Show the answer
Say this first
ipv6 route 2001:db8:acad:20::/64 GigabitEthernet0/0/1 fe80::2. You must give the exit interface because
every link has the fe80::/10 prefix, so fe80::2 alone does not say which link it is on. IOS rejects a
link-local next hop without an interface. Link-local next hops are a good habit: they survive renumbering of
the global prefix and match what routing protocols do.
Go deeper
The three forms
! fully specified, link-local next hop
ipv6 route 2001:db8:acad:20::/64 GigabitEthernet0/0/1 fe80::2
! recursive, global next hop
ipv6 route 2001:db8:acad:20::/64 2001:db8:acad:ff::2
! interface only
ipv6 route 2001:db8:acad:20::/64 GigabitEthernet0/0/1The interface-only trap
On Ethernet, an interface-only route makes the router treat every destination as on-link and send a Neighbor Solicitation for each one. The next router does not answer for addresses that are not its own, so the route fails. IPv4 often hides this mistake with proxy ARP; IPv6 does not. Use interface-only routes only on point-to-point interfaces like tunnels.
Floating static
ipv6 route ::/0 GigabitEthernet0/0/1 fe80::2
ipv6 route ::/0 GigabitEthernet0/0/2 fe80::3 200The second route has administrative distance 200 and only installs when the first goes away.
Make next hops readable
Set link-local addresses by hand on router links (ipv6 address fe80::1 link-local, fe80::2 on the other end)
so routes and neighbor tables are easy to read and do not change when a line card is swapped.
Other platforms
set routing-options rib inet6.0 static route 2001:db8:acad:20::/64 qualified-next-hop fe80::2 interface ge-0/0/1.0ip -6 route add 2001:db8:acad:20::/64 via fe80::2 dev eth1They will ask next
Does a floating static to a link-local next hop go away if the neighbor dies but the link stays up?
Not by itself. The route stays while the interface is up. Add BFD for static routes or IP SLA tracking if the link can stay up with a dead neighbor behind it.
What does the route look like in the table?
S 2001:DB8:ACAD:20::/64 [1/0]followed byvia FE80::2, GigabitEthernet0/0/1.
Traps
- Leaving out the interface with a link-local next hop.
- Using interface-only static routes on Ethernet and expecting proxy ARP behaviour.