Octet

How does DHCPv6 relay work, and what is DHCPv6 prefix delegation?

Show the answer

Say this first

A relay on the client's first-hop router catches the client's multicast to ff02::1:2, wraps it in a Relay-Forward message and unicasts it to the server. The link-address field tells the server which subnet the client is on. On IOS that is ipv6 dhcp relay destination on the client-facing interface. Prefix delegation (IA_PD) hands a whole prefix, such as a /56, to a requesting router, which then carves /64s from it for its own LANs. It is how ISPs give IPv6 to home and branch routers.

Go deeper

Relay

Cisco IOS
interface GigabitEthernet0/0/1
 ipv6 address 2001:db8:acad:20::1/64
 ipv6 nd managed-config-flag
 ipv6 nd prefix default no-autoconfig
 ipv6 dhcp relay destination 2001:db8:acad:100::10
  • Relay-Forward carries the link-address (a global address of the client's link), the peer-address (the client's link-local), and often an Interface-ID option.
  • The server answers with Relay-Reply. The relay unwraps it and sends the Reply to the client.
  • You still set the RA flags on the relay interface. Without M=1 clients never start DHCPv6.

Prefix delegation

Output
ISP router (delegating)  --->  CPE (requesting router)
IA_PD: 2001:db8:5600::/56       LAN1 2001:db8:5600:1::/64
                                LAN2 2001:db8:5600:2::/64

On an IOS CPE:

Cisco IOS
interface GigabitEthernet0/0/1
 description WAN to ISP
 ipv6 address autoconfig default
 ipv6 dhcp client pd FROM-ISP
!
interface GigabitEthernet0/0/0
 ipv6 address FROM-ISP ::1:0:0:0:1/64

FROM-ISP is a general prefix name. The LAN gets 2001:db8:5600:1::1/64 and follows automatically if the ISP changes the delegated prefix.

The return route

Something upstream must route the delegated /56 to the CPE. Broadband gear and many relays install that route when they see the delegation. If nothing does, the CPE gets its prefix and nothing comes back.

Traps

  • Forgetting the M flag on the relay interface.
  • Assuming the delegated prefix is routed to the CPE by magic.
How did you do?Book 4.2 IP Version 6