SLAAC and DHCPv6 – Exclusive Details
Remember that we already discussed the introduction of the SLAAC and DHCPv6 in Router Advertisement (RA) messages. Now, we will briefly discuss both SLAAC and DHCPv6. Recall that the router sends a Router Advertisement (RA) message. The setting of the Router Advertisement (RA) message decides whether a client can obtain its IPv6 address information automatically using SLAAC, DHCPv6, or a combination of both.
The Router Advertisement (RA) message always contains the Managed Address Configuration flag (M flag) and another configuration flag (O Flag) with a different combination. The combination of M Flag and O Flag tells the host how he can get an IPv6 address. The RA message presents three addressing options for the IPv6-enabled devices using a different combination of M Flag and O Flag.
- SLAAC – Use of SLAAC Only
- Stateless DHCPv6 – Use of both SLAAC and DHCPv6
- Stateful DHCPv6 – Use of DHCPv6 Server Only
The RA message specifies the above three options for the client to obtain an IPv6 address, but the client computer doesn’t need to choose one of them. The client computer can ignore the RA message and use the services of a DHCPv6 server exclusively.
RFC 4861 recommends detecting Duplicate Addresses (DAD) on any unicast address and address configured with SLAAC and DHCPv6. This ensures that all configured IPv6 addresses are unique on the particular subnet.
SLAAC Option
It is the default option on Cisco routers. The M flag and the O flag value are set to 0 in the RA for this option. It simplifies IPv6 address management by providing plug-and-play IP connectivity without manual configuration of hosts. It enables an IPv6 client to create its IPv6 addresses using a combination of locally available information and information advertised by routers through an RA message.
In the SLAAC option, the client uses the information in the RA message exclusively. The information in the RA message includes a prefix, prefix length, DNS server, Maximum Transmission Unit, and default gateway. The client does not use any information from the DHCPv6 server. The IPv6 global unicast address combines the advertised link-local prefix (first 64 bits) with the interface identifier (last 64 bits).
The RA option is configured on an individual router interface. If it is configured with other options, e.g., stateless DHCPv6 or stateful DHCPv6. To re-configure an interface for SLAAC, the M flag, and O flags are required to reset to initial values of 0. The configuration command is the following:
Router(config-if)# no ipv6 nd managed-config-flag
Router(config-if)# no ipv6 nd other-config-flag
Stateless DHCPv6 Option
The function of DHCPv6 is similar to DHCPv4.It also runs between a client and a server. Like DHCP for IPv4, DHCPv6 clients and DHCPv6 servers exchange DHCPv6 packets using the UDP. In IPv6, packets cannot be broadcast; therefore, DHCPv6 uses multicast packets. In this case, DHCPv6 clients do not need to be configured with IPv6 addresses of DHCPv6 servers.
In this option, the client used both information available in the RA message and a DHCPv6 server. The client gets the addressing information from the RA message, but additional parameters for configuration are available from a DHCPv6 server. The client creates its IPv6 global unicast address using the prefix and prefix length in the RA message, along with the EUI-64 process or a randomly generated ID.
After configuring the IP addressing information, the client communicates with a stateless DHCPv6 server to get supplementary information. This process is called stateless DHCPv6 because the server does not maintain any client state information, such as the state of available and allocated IPv6 addresses. The server only provides configuration parameters for clients, not IPv6 addresses.
The O flag is set to 1, and the M is set to 0 for the stateless DHCPv6 option. The O flag value of 1 tells the client that additional configuration information is available from a stateless DHCPv6 server. To configure and modify the RA message, enter into the concern interface mode and use the following command:
Router(config-if)# ipv6 nd other-config-flag
Stateful DHCPv6 Option
It works like DHCP for IPv4 addresses. A device can get its addressing plan and information, including a global unicast address, prefix length, and the addresses of DNS servers, automatically using the services of a stateful DHCPv6 server. The RA message in this option informs the client that I can’t give you any information you need. Send a request to the DHCPv6 server for all your required information. This option is stateful DHCPv6 because the DHCPv6 server keeps all records and states of IPv6 addresses.
The M and O flags must be set to 1 in stateful DHCPv6. The following command is used to change the M flag and O flag from 0 to 1 to apply stateful DHCPv6:
Router(config-if)# ipv6 nd managed-config-flag
Router(config-if)# ipv6 nd other-config-flag
DHCPv6 Operation » Networkustad
October 5, 2019 @ 8:23 am
[…] of the stateless and stateful DHCPv6 operation are started with an ICMPv6 RA message from the router. The RA message may have been […]
Stateless DHCPv6 Server Configuration » Networkustad
October 5, 2019 @ 7:42 pm
[…] Configuring stateless DHCPv6 server on the Cisco router, it is important to enabling IPv6 unicast routing. The unicast routing […]
Stateful DHCPv6 Server configuration » Networkustad
October 6, 2019 @ 7:17 am
[…] can configure the stateful DHCPv6 server is similar to configuring a stateless server. The difference between stateless and stateful […]