Configure DHCPv6 Server
Summary
This topic configure a stateful and stateless DHCPv6 server. Start learning CCNA 200-301 for free right now!!
Table of Contents
DHCPv6 Router Roles
Cisco IOS routers are powerful devices. In smaller networks, you do not have to have separate devices to have a DHCPv6 server, client, or relay agent. A Cisco IOS router can be configured to provide DHCPv6 server services.
Specifically, it can be configured to be one of the following:
- DHCPv6 Server – Router provides stateless or stateful DHCPv6 services.
- DHCPv6 Client – Router interface acquires an IPv6 IP configuration from a DHCPv6 server.
- DHCPv6 Relay Agent – Router provides DHCPv6 forwarding services when the client and the server are located on different networks.
Configure a Stateless DHCPv6 Server
The stateless DHCPv6 server option requires that the router advertise the IPv6 network addressing information in RA messages. However, the client must contact a DHCPv6 server for more information.
Refer to the sample topology to learn how to configure the stateless DHCPv6 server method.
In this example, R1 will provide SLAAC services for the host IPv6 configuration and DHCPv6 services.
There are five steps to configure and verify a router as a stateless DHCPv6 server:
Step 1. Enable IPv6 routing.
Step 2. Define a DHCPv6 pool name.
Step 3. Configure the DHCPv6 pool.
Step 4. Bind the DHCPv6 pool to an interface.
Step 5. Verify that the hosts have received IPv6 addressing information.
Click each button for an example of these steps.
Configure a Stateless DHCPv6 Client
A router can also be a DHCPv6 client and get an IPv6 configuration from a DHCPv6 server, such as a router functioning as a DHCPv6 server. In the figure, R1 is a stateless DHCPv6 server.
There are five steps to configure and verify a router as a stateless DHCPv6 server.
Step 1. Enable IPv6 routing.
Step 2. Configure the client router to create an LLA.
Step 3. Configure the client router to use SLAAC.
Step 4. Verify that the client router is assigned a GUA.
Step 5. Verify that the client router received other necessary DHCPv6 information.
Click each button for an example of these steps.
Configure a Stateful DHCPv6 Server
The stateful DHCP server option requires that the IPv6 enabled router tells the host to contact a DHCPv6 server to obtain all necessary IPv6 network addressing information.
In the figure, R1 will provide stateful DHCPv6 services to all hosts on the local network. Configuring a stateful DHCPv6 server is similar to configuring a stateless server. The most significant difference is that a stateful DHCPv6 server also includes IPv6 addressing information similar to a DHCPv4 server.
There are five steps to configure and verify a router as a Stateful DHCPv6 server:
Step 1. Enable IPv6 routing.
Step 2. Define a DHCPv6 pool name.
Step 3. Configure the DHCPv6 pool.
Step 4. Bind the DHCPv6 pool to an interface.
Step 5. Verify that the hosts have received IPv6 addressing information.
Click each button for an example of these steps.
Configure a Stateful DHCPv6 Client
A router can also be a DHCPv6 client. The client router needs to have ipv6 unicast-routing enabled and an IPv6 link-local address to send and receive IPv6 messages.
Refer to the sample topology to learn how to configure the stateful DHCPv6 client.
There are five steps to configure and verify a router as a Stateful DHCPv6 server.
Step 1. Enable IPv6 routing.
Step 2. Configure the client router to create an LLA.
Step 3. Configure the client router to use DHCPv6.
Step 4. Verify that the client router is assigned a GUA.
Step 5. Verify that the client router received other necessary DHCPv6 information.
Click each button for an example of these steps.
DHCPv6 Server Verification Commands
Use the show ipv6 dhcp pool and show ipv6 dhcp binding commands to verify DHCPv6 operation on a router.
Click each button for example output.
Configure a DHCPv6 Relay Agent
If the DHCPv6 server is located on a different network than the client, then the IPv6 router can be configured as a DHCPv6 relay agent. The configuration of a DHCPv6 relay agent is similar to the configuration of an IPv4 router as a DHCPv4 relay.
In the figure, R3 is configured as a stateful DHCPv6 server. PC1 is on the 2001:db8:acad:2::/64 network and requires the services of a stateful DHCPv6 server to acquire its IPv6 configuration. R1 needs to be configured as the DHCPv6 Relay Agent.
The command syntax to configure a router as a DHCPv6 relay agent is as follows:
Router(config-if)# ipv6 dhcp relay destination ipv6-address [interface-type interface-number]
This command is configured on the interface facing the DHCPv6 clients and specifies the DHCPv6 server address and egress interface to reach the server, as shown in the output. The egress interface is only required when the next-hop address is an LLA.
R1(config)# interface gigabitethernet 0/0/1 R1(config-if)# ipv6 dhcp relay destination 2001:db8:acad:1::2 G0/0/0 R1(config-if)# exit R1(config)#
Verify the DHCPv6 Relay Agent
Verify that the DHCPv6 relay agent is operational with the show ipv6 dhcp interface and show ipv6 dhcp binding commands. Verify Windows hosts received IPv6 addressing information with the ipconfig /all command.
Click each button for example output.
Ready to go! Keep visiting our networking course blog, give Like to our fanpage; and you will find more tools and concepts that will make you a networking professional.