DHCPv6 relay agent configuration example
Network requirements
As shown in
between DHCPv6 clients and the DHCPv6 server.
Switch A acts as the gateway of network 1::/64. It sends RA messages to notify the hosts to obtain
IPv6 addresses and other configuration parameters through DHCPv6. For more information about
RA messages, see
Figure 78 Network diagram
DHCPv6 client
DHCPv6 client
Configuration procedure
# Specify IPv6 addresses for VLAN-interface 2 and VLAN-interface 3.
<SwitchA> system-view
[SwitchA] interface vlan-interface 2
[SwitchA-Vlan-interface2] ipv6 address 2::1 64
[SwitchA-Vlan-interface2] quit
[SwitchA] interface vlan-interface 3
[SwitchA-Vlan-interface3] ipv6 address 1::1 64
# Disable RA message suppression on VLAN-interface 3.
[SwitchA-Vlan-interface3] undo ipv6 nd ra halt
# Set the M flag to 1 in RA advertisements to be sent on VLAN-interface 3. Hosts that receive the RA
advertisements will obtain IPv6 addresses through DHCPv6.
[SwitchA-Vlan-interface3] ipv6 nd autoconfig managed-address-flag
# Set the O flag to 1 in RA advertisements to be sent on VLAN-interface 3. Hosts that receive the RA
advertisements will obtain information other than IPv6 address through DHCPv6.
[SwitchA-Vlan-interface3] ipv6 nd autoconfig other-flag
# Enable the DHCPv6 relay agent on VLAN-interface 3 and specify the DHCPv6 server on the relay
agent.
[SwitchA-Vlan-interface3] ipv6 dhcp select relay
[SwitchA-Vlan-interface3] ipv6 dhcp relay server-address 2::2
Figure
78, configure the DHCPv6 relay agent on Switch A to relay DHCPv6 packets
"Configuring basic IPv6
DHCPv6 client
Vlan-int3
1::1/64
Switch A
DHCPv6 relay agent
DHCPv6 client
settings."
Vlan-int2
2::1/64
2::2/64
DHCPv6 server
214