Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP

Instructor Planning Guide

Activities

What activities are associated with this chapter?

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 45

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 46

Assessment

Students should complete Chapter 8, “Assessment” after completing Chapter 8.

Quizzes, labs, Packet Tracers and other activities can be used to informally assess student progress.

Sections & Objectives

8.1 DHCPv4

Implement DHCPv4 to operate across multiple LANs in a small to medium-sized business network.

Explain how DHCPv4 operates in a small- to medium-sized business network.

Configure a router as a DHCPv4 server.

Configure a router as a DHCPv4 client.

Troubleshoot a DHCP configuration for IPv4 in a switched network.

8.2 DHCPv6

Implement DHCPv6 to operate across multiple LANs in a small to medium-sized business network.

Explain the operation of DHCPv6.

Configure stateless DHCPv6 for a small to medium-sized business.

Configure stateful DHCPv6 for a small to medium-sized business.

Troubleshoot a DHCP configuration for IPv6 in a switched network.

Chapter 8: DHCP

8.1 – DHCPv4

8.1.1 – DHCPv4 Operation

8.1.1.1 – Introducing DHCPv4

DHCPv4 assigns IPv4 addresses and other network configuration information dynamically.

  • A dedicated DHCPv4 server is scalable and relatively easy to manage.
  • A Cisco router can be configured to provide DHCPv4 services in a small network.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 47

8.1.1.2 – DHCPv4 Operation

Four step process for a client to obtain a lease:

  1. DHCP Discover (DHCPDISCOVER) – client uses Layer 2 and Layer 3 broadcast addresses to find a DHCP server.
  2. DHCP Offer (DHCPOFFER) – DHCPv4 server sends the binding DHCPOFFER message to the requesting client as a unicast.
  3. DHCP Request (DHCPREQUEST) – the client sends back a broadcast DHCPREQUEST in response to the servers offer.
  4. DHCP Acknowledgment (DHCPACK) – the server replies with a unicast DHCPACK message.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 48

8.1.1.3 – DHCPv4 Message Format

DHCPv4 messages:

  • If sent from the client, use UDP source port 68 and destination port 67.
  • If sent from the server, use UDP source port 67 and destination port 68.
Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 49

Format and fields of a DHCPv4 Message

8.1.1.4 – DHCPv4 Discover and Offer Messages

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 50

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 51

8.1.2 – Configuring a Basic DHCPv4 Server

8.1.2.1 – Configuring a Basic DHCPv4 Server

Configuring a Cisco router as a DHCPv4 server:

  • Excluding IPv4 Addresses – ip dhcp excluded-address can exclude a single address or a range of addresses from being assigned.
  • Configuring a DHCPv4 Pool – ip dhcp pool pool-name command creates a pool with the specified name and puts the router in DHCPv4 configuration mode.
  • Address pool assigned using network command.
  • Default gateway assigned using default-router command.
  • Other commands are optional.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 52

8.1.2.2 – Verifying DHCPv4

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 53

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 54

Verify DHCPv4 configuration using the show running-config |section dhcp command.

Verify the operation of DHCPv4 using the show ip dhcp binding command.

Verify that messages are being received or sent by the router using the show ip dhcp server statistics command.

8.1.2.3 – DHCPv4 Relay

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 55

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 56

DHCPDISCOVER messages are sent as broadcast messages.

Routers do not forward broadcasts.

A Cisco IOS helper address is configured so that the router acts as a relay agent forwarding the message to the DHCPv4 server.

8.1.2.4 – Lab – Configuring Basic DHCPv4 on a Router

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 57

8.1.2.5 – Lab – Configuring Basic DHCPv4 on a Switch

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 58

8.1.3 – Configure DHCPv4 Client

8.1.3.1 – Configuring a Router as DHCPv4 Client

Small office/home office (SOHO) and branch sites often have to be configured as DHCPv4 clients.

Use the ip address dhcp interface configuration mode command.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 59

8.1.3.2 – Configuring a Wireless Router as a DHCPv4 Client

Wireless routers are set to receive IPv4 addressing information automatically from the ISP.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 60

8.1.3.3 – Packet Tracer – Configuring DHCPv4 Using Cisco IOS

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 61

8.1.4 – Troubleshoot DHCPv4

8.1.4.1 – Troubleshooting Tasks

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 62

8.1.4.2 – Verify Router DHCPv4 Configuration

Verify DHCPv4 Relay – use show running-config command to verify that the ip helper address is configured.

Verify DHCPv4 configuration – use the show running-config | include no service dhcp command to verify dhcp is enabled because there is no match for the no service dhcp.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 63

8.1.4.3 – Debugging DHCPv4

The extended ACL is used with the debug ip packet command to display only DHCPv4 messages.

Another troubleshooting command is the debug ip dhcp server events.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 64

8.1.4.4 – Lab – Troubleshooting DHCPv4

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 65

8.2 – DHCPv6

8.2.1– SLAAC and DHCPv6

8.2.1.1 – Stateless Address Autoconfiguration (SLAAC)

Two methods to dynamically assign IPv6 global unicast addresses:

  • Stateless Address Autoconfiguration (SLAAC).
  • Dynamic Host Configuration Protocol for IPv6 (Stateful DHCPv6).

SLAAC uses ICMPv6 Router Solicitation and Router Advertisement messages to provide addressing and other configuration information.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 66

8.2.1.2 – SLAAC Operation

The router must have IPv6 routing enabled– ipv6 unicast-routing

PC1 sends an RS message to the all-routers multicast address that it needs an RA.

R1 responds with an RA message that has the prefix and prefix length of the network.

PC1 uses this information to create its IPv6 global unicast address. It creates its interface id using EUI-64 or randomly generates it.

PC1 must verify that the address is unique by sending an ICMPv6 Neighbor Solicitation message.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 67

8.2.1.3 – SLAAC and DHCPv6

Different combinations of the Managed Address Configuration flag (M flag) and the Other Configuration flag (O flag) in the RA determine how the IPv6 address is assigned:

  • SLAAC (Router Advertisement only)
  • Stateless DHCPv6 (Router Advertisement and DHCPv6)
  • Stateful DHCPv6 (DHCPv6 only)

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 68

8.2.1.4 – SLAAC Option

SLAAC is the default on Cisco routers. Both the M flag and the O flag are set to 0 in the RA.

This option instructs the client to use the information in the RA message only.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 69

8.2.1.5 – Stateless DHCPv6 Option

DHCPv6 is defined in RFC 3315.

Stateless DHCPv6 option – client uses the RA message for addressing, additional parameters are obtained from DHCPv6 server.

O flag is set to 1 and the M flag is left at the default setting of 0. Use command ipv6 nd other-config-flag.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 70

8.2.1.6 – Stateful DHCPv6 Option

RA message informs the client not to use the information in the RA message.

All addressing and configuration information must be obtained from a stateful DHCPv6 server.

M flag is set to 1. Use the command ipv6 nd managed-config-flag.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 71

8.2.1.7 – DHCPv6 Operations

DHCPv6 messages from server to client use UDP port 546. Client to server use UDP port 547.

Client sends a DHCPv6 SOLICIT message using FF02::1:2.

DHCPv6 server responds with a DHCPv6 ADVERTISE unicast message.

Stateless DHCPv6 client – Generates its own address. Sends a DHCPv6 INFORMATION-REQUEST to the DHCPv6 server requesting only configuration parameters.

Stateful DHCPv6 client – Sends a DHCPv6 REQUEST message to server for an IPv6 address and all other configuration parameters.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 72

8.2.2– Stateless DHCPv6

8.2.2.1 – Configuring a Router as a Stateless DHCPv6 Server

Step 1 – Enable IPv6 routing. ipv6 unicast-routing

Step 2 – Configure a DHCPv6 pool. ipv6 dhcp pool pool-name

Step 3 – Configure pool parameters. dns-server server-address

Step 4 – Configure the DHCPv6 interface ipv6 dhcp server pool-name

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 73

8.2.2.2 – Configuring a Router as a Stateless DHCPv6 Client

Step 1 – IPv6 enabled on interface ipv6 enable

Step 2 – enable automatic configuration of IPv6 addressing ipv6 address autoconfig

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 74

8.2.2.3 – Verifying Stateless DHCPv6

Commands to verify Stateless DHCPv6:

  • show ipv6 dhcp pool
  • show running-config
  • show ipv6 interface
  • debug ipv6 dhcp detail

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 75

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 76

8.2.3– Stateful DHCPv6 Server

8.2.3.1 – Configuring a Router as a Stateful DHCPv6 Server

Step 1 – Enable IPv6 Routing.

  • ipv6 unicast routing

Step 2 – Configure a DHCPv6 pool.

  • ipv6 dhcp pool pool-name

Step 3 Configure pool parameters:

  • address prefix prefix/length
  • dns-server dns-server-address
  • domain-name domain-name

Step 4 Configure DHCPv6 interface:

  • ipv6 dhcp server pool-name
  • ipv6 nd managed-config-flag

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 77

8.2.3.2 – Configuring a Router as a Stateful DHCPv6 Client

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 78

Step 1 – Allow the router to send RS messages and participate in DHCPv6.

  • ipv6 enable

Step 2 – Make the router a DHCPv6 client.

  • ipv6 address dhcp

8.2.3.3 – Verifying Stateful DHCPv6

Use the following commands to verify Stateful DHCPv6:

  • show ipv6 dhcp pool
  • show ipv6 dhcp binding
  • show ipv6 interface

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 79

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 80

8.2.3.4 – Configuring a Router as a DHCPv6 Relay Agent

If the DHCPv6 server is located on a different network than the client, the router can be configured as a DHCPv6 relay agent.

  • ipv6 dhcp relay destination destination-address

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 81

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 82

8.2.3.5 – Lab – Configuring Stateless and Stateful DHCPv6

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 83

8.2.4– Troubleshoot DHCPv6

8.2.4.1 – Troubleshooting Tasks

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 84

8.2.4.2 – Verify Router DHCPv6 Configuration

Use the show ipv6 interface command to verify DHCPv6 configuration.

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 85

8.2.4.3 – Debugging DHCPv6

To verify the receipt and transmission of DHCPv6 messages:

  • debug ipv6 dhcp detail

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 86

8.2.4.4 – Lab – Troubleshooting DHCPv6

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 87

8.3 – Summary

8.3.1 – Conclusion

8.3.1.1 – Packet Tracer – Skills Integration Challenge

Routing and Switching Essentials 6.0 Instructor Materials – Chapter 8: DHCP 88

8.3.1.3 – Chapter 8: DHCP

Implement DHCPv4 to operate across multiple LANs in a small to medium-sized business network.

Implement DHCPv6 to operate across multiple LANs in a small to medium-sized business network.

New Terms and Commands

•Dynamic Host Configuration Protocol (DHCP)

•DHCPv4

•DHCPv6

•lease

•DHCPDISCOVER message

•DHCPOFFER message

•DHCPREQUEST message

•DHCPACK message

•DHCP Options

•client IPv4 address (CIADDR)

•default gateway address (GIADDR)

•Cisco IOS helper address

•DHCPv4 relay agent

•Stateless Address Autoconfiguration (SLAAC)

•stateless DHCPv6 server

•stateful DHCPv6 server

•Internet Control Message Protocol version 6 (ICMPv6)

•Router Solicitation (RS) message

•Router Advertisement (RA) message

•Interface ID (IID)

•EUI-64

•Neighbor Solicitation (NS) message

•solicited-node multicast address

•Neighbor Advertisement (NA) message

•Duplicate Address Detection (DAD)

•Managed Address Configuration flag (M flag)

•Other Configuration flag (O flag)

•stateful DHCPv6

•DHCPv6 SOLICIT message

•DHCPv6 ADVERTISE unicast message

•DHCPv6 REQUEST message

•DHCPv6 INFORMATION-REQUEST message

•Stateless DHCPv6 client

•Stateful DHCPv6 client

•DHCPv6 REPLY unicast message atelesunicast message

Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x