Configuring a Peer Device for DHCPv6 Address Auto-configuration
- Enter global configuration mode.
- Enter interface configuration mode.
- Configure an IPv6 address for the interface.
- Enable IPv6 for the interface.
- Configure the prefixes to be
included in router advertisement (RA) messages. The peer router is configured to advertise the prefix 3010::/64 in router advertisement (RA) messages sent out on Ethernet interface 1/1/5 with a valid lifetime of 3000 seconds, a preferred lifetime of 3000 seconds, and the onlink flag set.
- Enable the managed configuration flag for IPv6.The peer router is configured to send RA messages with the Managed Configuration Flag (M-flag) set to 1, indicating that the client should use DHCPv6 to obtain its IPv6 address.
This following example configures a peer router for stateful DHCPv6 address auto-configuration.
device# configure terminal device(config)# interface ethernet 1/1/5 device(config-if-e1000-1/1/5)# ipv6 address 3010::1/64 device(config-if-e1000-1/1/5)# ipv6 enable device(config-if-e1000-1/1/5)# ipv6 nd prefix-advertisement 3010::/64 3000 3000 onlink device(config-if-e1000-1/1/5)# ipv6 nd managed-config-flag
This following example configures a peer router for stateless DHCPv6 address auto-configuration. For stateless address configuration, a device obtains network configuration parameters, such as domain name server (DNS) and domain search list, from a DHCPv6 server without obtaining an IPv6 address from the server. Instead, the IPv6 address is auto-configured using Router Advertisements (RA).
device# configure terminal device(config)# interface ethernet 1/1/6 device(config-if-e1000-1/1/6)# ipv6 address 3010::1/64 device(config-if-e1000-1/1/6)# ipv6 enable device(config-if-e1000-1/1/6)# ipv6 nd prefix-advertisement 3010::/64 3000 3000 onlink autoconfig device(config-if-e1000-1/1/6)# ipv6 nd other-config-flag