Share via


Hands-on exercises for Module 5: DHCPv6

These hands-on exercises are designed for Module 5: DHCPv6 of the Microsoft IPv6 course from the Microsoft Virtual Academy. They demonstrate the following:

  • Configuring DHCPv6 for the network, including specifying the option for the IPv6 address of a DNS server
  • Verifying that DNS client traffic is being sent over IPv6

These hands-on exercises assume that you have built the following IPv6 test lab based on the Hands-on exercises for Module 4: Practical aspects of IPv6 article.

This procedure adds DHCPv6 support to the IPv6 test lab.

  1. Use the Hyper-V Manager to connect to DC1 and log in using the CORP\User1 account.
  2. Open an administrator-level Windows PowerShell command prompt and run the ipconfig command. Note the IPv6 Address here: _______________________________
  3. Fill in the IPv6 address for DC1 and run these commands at an administrator-level Windows PowerShell command prompt to add IPv6 scopes and a scope option:

$dc1Address="<the IPv6 address of DC1>"

Add-DhcpServerv6Scope -Name "Corpnet" -Prefix 2001:db8::

Add-DhcpServerv6Scope -Name "Corpnet2" -Prefix 2001:db8:0:2::

Set-DhcpServerv6OptionValue –OptionID 23 -Value $dc1Address

 

Use the Hyper-V Manager to connect to RTR1 and log in using the local administrator account.

Open an administrator-level Windows PowerShell command prompt and run the following commands to configure RTR1 to send Router Advertisement messages with the Managed Address Configuration and Other Stateful Configuration flags set to 1:

Set-NetIPInterface -InterfaceAlias Corpnet -AddressFamily IPv6 -AdvertiseDefaultRoute Enabled –Forwarding Enabled -Advertising Enabled -ManagedAddressConfiguration Enabled -OtherStatefulConfiguration Enabled

Set-NetIPInterface -InterfaceAlias Corpnet2 -AddressFamily IPv6 -AdvertiseDefaultRoute Enabled –Forwarding Enabled -Advertising Enabled -ManagedAddressConfiguration Enabled -OtherStatefulConfiguration Enabled

This procedure configures the DHCPv6 relay agent on RTR1.

  1. Click Start, type routing, and then click Routing and Remote Access.
  2. In the console tree, expand IPv6. Right-click General, and then click New Routing Protocol.
  3. In New Routing Protocol, click DHCPv6 Relay Agent, and then click OK.
  4. In the console tree, right-click DHCPv6 Relay Agent, click New Interface, click Corpnet2, and then click OK twice.
  5. Right-click DHCPv6 Relay Agent, and then click Properties.
  6. On the Servers tab, type the IPv6 address of DC1 from step 2 of the previous procedure, click Add, and then click OK.

Using the Hyper-V Manager, change CLIENT1's network adapter to use the Corpnet2 virtual switch. At the Windows PowerShell command prompt, run ipconfig /renew until you get an IPv4 address that starts with "10.0.2".

Note that in the display of ipconfig, you have two permanent IPv6 addresses: one is from the router advertisement from RTR1 and one is a DHCPv6-assigned address from DC1. This is normal behavior for this network because the Windows-based router does not support setting the Autonomous flag to 0 in the Prefix Information option of Router Advertisement messages.

Run ipconfig /all to see information on the DHCPv6 server, including the assignment of DC1's IPv6 address for a DNS server.

Run nslookup. Note that the default server has been contacted over its IPv6 address.

At the nslookup prompt, type app1. Note that the resolution of the app1.corp.contoso.com name has been sent over IPv6.

At the nslookup prompt, type exit.

The following procedure configures a client reservation for APP1.

  1. On DC1, click Start, type DHCP, and then click DHCP.
  2. In the console tree, open dc1.corp.contoso.com > IPv6 > Scope [2001:db8::] Corpnet, and then click Address Leases. Notice the address lease for APP1.
  3. Right-click the address lease for APP1, and then click Add to Reservation.
  4. Click Reservations. You should see the reservation for APP1.

To continue your hands-on learning about IPv6, see Hands-on exercises for Module 6: DNS with IPv6.