Both SLAAC and DHCPv6 can deliver IPv6 addresses, so which one should I use?
This issue shares IPv6-related knowledge with you.
Background discussion
When discussing IPV6 intranet transformation solutions, there is often a question: "IPv6 protocol can be configured through SLAAC stateless address, why do we still need to configure a DHCPv6 server on the core switch? Are the two alternatives?" In fact, although SLAAC can realize some functions, it cannot completely replace DHCPv6 in actual networking.
How to configure and automatically obtain IPv6 addresses?
IPv6 address automatic configuration can be divided into stateless address automatic configuration (SLAAC) and stateful address automatic configuration (DHCPv6);
Whether to use stateless address automatic configuration or stateful address automatic configuration is determined by the server;
The client determines whether to use stateless or stateful address configuration through the M and O flags in the RA packet replied by the server;
Since IPv6 address resources are sufficient, in actual applications, the terminals can obtain IPv6 public network addresses.
Two automatic configuration methods - stateless SLAAC and stateful DHCPv6
Alas, I am really annoyed by the concept of stateless/stateless here, because under SLAAC allocation, there will be interaction with DHCPv6 to obtain parameters such as DNS, which experts call stateful under SLAAC; and if there is no stateless under SLAAC... Then, the whole process of IPv6 address allocation dominated by DHCPv6 is stateful, which is a mouthful, isn't it? It's really annoying.
In short, for me, I only care about the following four points:
SLAAC uses ICMPv6 RA/RS packet interaction;
DHCPv6 uses DHCPv6 packet interaction;
SLAAC automatic configuration is that the server tells the client an IPv6 prefix, and then the client generates an IPv6 address according to EUI-64. The server does not care what the address is;
DHCPv6 automatic configuration means that the server completely sends parameters to the client. Just like IPv4 DHCP, the server firmly controls the IPv6 address pool.
Under what circumstances should SLAAC and DHCPv6 be used?
Some Android phones only support SLAAC. If there are many such devices in the network, use SLAAC.
If you need to monitor IPv6 addresses, set up DHCPv6 on the core switch (server).
Someone asked: Are there core switches or routers that can support SLAAC and DHCPv6 at the same time? My answer: Yes, this is hybrid automatic configuration, and most home routers support it.