19 Dynamic Host Configuration Protocol – Windows

Raechel Ferguson

Dynamic Host Configuration Protocol (DHCP) is an interacting client-server protocol that automatically provides a host (PC, Laptop, Phone, etc) with an Internet Protocol (IP) address upon request.  The purpose of this activity is for learners to see DHCP in action instead of just reading about the DHCP handshake theory.  A secondary purpose is for learners to experience frustration when hosts do not get a DHCP IP address.  Learners can see how the packets move and where they may get hung up while working on making DHCP function correctly on their network.  Finally, learners will be able to see Address Resolution Protocol (ARP) in action.  While DHCP occurs when a host requests an IP address for an existing MAC address, ARP is when a host has an IP address, but is unsure what MAC address it belongs to.

Estimated time for completion: 20 minutes

Learning objectives

  • Successfully deploy a DHCP solution using Windows on an enterprise network
  • Capture and Observe DHCP packets using Wireshark
  • Capture and Observe ARP packets using Wireshark
  • Successfully add hosts to an enterprise network and receive IP addresses automatically



  • 4 Screenshots:
    • Wireshark – DHCP Packets for PC2
    • Wireshark – DHCP Packets for PC3
    • GNS3 Workspace
    • Configuration of Windows Server


Contributors and testers

  • Mathew J. Heath Van Horn, PhD, ERAU-Prescott
  • Julian Romano, Cybersecurity Student, ERAU-Prescott
  • Dante Rocca, Cybersecurity Student, ERAU-Prescott
  • Jacob M. Christensen, Cybersecurity Student, ERAU-Prescott

Phase I -Build the Network Topology

The following steps are to create the baseline for completing the lab. It makes assumptions about learner knowledge from completing previous labs. By the end of this lab, your network should look like the following:

GNS3 network environment
Figure 1 – Final GNS3 network environment
  1.   Open GNS3 and start a new workspace
    1. Create a new project: LAB_05
  2. Create the baseline network with an address space of

    NOTE: This example uses the same network topology that was created in the previous chapter: DHCP using Linux.

    1. Use two VPCS devices for PC1 and PC2
    2. Add an Ethernet switch
    3. Add a Windows Server VM and rename it to “DHCP-server”

      NOTE: Ensure that the Allow GNS3 to use any configured VirtualBox adapter check box is selected for all VMs added to GNS3. Refer to  step 6.2 in Chapter 11 for more information.

    4. Connect the server and PCs to the switch
    5. Label and organize your network as necessary
      GNS3 network environment
      Figure 2 – GNS3 network environment

Phase II – Configure the Network Interface of the Server

In order for the server to act as a DHCP server we will need the server to be properly attached to the network. Without giving it the proper network information our server will be unable to talk with any other computers on the network.

  1. Start the server and login
  2. Focus on the Server Manager dashboard window 1
    Windows Server Manager Dashboard
    Figure 3 – Windows Server Manager Dashboard

    NOTE: If the Server Manager does not start on boot, can open it via the Windows Start menu.

  3. On the left side of the page, select the Local Server option
  4. Assign the IP address to the local ethernet interface
    1.  Under the PROPERTIES table, left-click on the Ethernet option (Figure 41

      NOTE: This is located beneath NIC Teaming and above Operating system version.

    2. Right-click on the network interface you want to use (e.g. “Ethernet”) and select Properties in the context menu (Figure 51
    3. A new sub-window labeled Ethernet Properties should appear
      1. Uncheck Internet Protocol Version 6 (TCP/IPv6) 1
      2. Check and highlight the Internet Protocol Version 4 (TCP/IPv4) option 1
      3. On the bottom right corner, click on Properties (Figure 61
    4. A new sub-window labeled Internet Protocol Version 4 (TCP/IPv4) Properties should appear (Figure 71
      1. Select Use the following IP address
        1. Enter as the IP address 1
        2. Enter as the Subnet mask 1
        3. Enter as the Default gateway 1
      2. Select Use the following DNS server addresses
        1. Enter as the Preferred DNS server 1
        2. Leave the Alternate DNS server blank 1
      3. Click OK to apply these settings 1
      4. Click Close to return to the Network Connections window
    5. Close the Network Connections window
  5. Restart Windows Server

Phase III – Setup the DHCP Server

Windows Server is capable of many functions and is very customizable. Therefore, to minimize installation times, Windows Server on initial installation does not come with many features activated. We will need to activate and configure Windows Active Directory and DHCP services.

  1. Focus on the Server Manager dashboard window 2
  2. In the top right-hand corner of the screen, select Manage  2
  3. Select Add Roles and Features from the context menu  2
  4. A popup window labeled Add Roles and Features Wizard will open (Figure 8)
    1. Before you Begin – Click Next  2
    2. Installation Type – Select the Role-Based option – then click Next (Figure 92
    3. Server Selection – Select your local server (this should be the only option) then click Next (Figure 102
    4. Server Roles – select DHCP Server  2
      1. POP-UP – Add Features – Select Add Features towards the bottom of the new screen (Figure 112
      2. Return back to Server Roles – Click Next  2
    5. Features – Click Next  2
    6. DHCP Server – Click Next  2
    7. Confirmation – Click Install  2
    8. Once installation is complete click on the blue text that states Complete DHCP Configuration (Figure 122
  5. POP-UP – DHCP Post-Install Configuration Wizard
    1. Description – Click Next  2
    2.  Authorization – Click Commit  2

      NOTE: The default authorization should be set to use Administrator credentials.  If it doesn’t, you’ve done something wrong and need to restart.

    3. Summary – Click Close  2
  6. Return to Rolls and Features Wizard
    1. Results – Click Close  2
  7. Restart Windows Server

Phase IV – Configure DHCP

DHCP is widely flexible.  In this lab, we are going to assign a range of IP addresses that can be used by end devices connecting to our network without a manually configured IP address.

  1. Focus on the Server Manager dashboard window
  2. In the top right-hand corner of the screen, select Tools  2
  3. From the drop-down menu, select DHCP  2
  4. A new sub-window labeled DHCP should appear
    1. Expand the local computer forest (Figure 132
    2. Right-click on the IPv4 option and select New Scope from the context menu (Figure 142
  5. The New Scope Wizard window will open
    1. Scope Wizard Welcome – Click Next (Figure 152
    2. Scope Name (Figure 16)
      1. Add a name such as Scope1 2
      2. The description field can be left blank
      3. Click Next  2
    3. IP Address Range (Figure 172
      1. Start IP address –
      2. End IP address –
      3. Length – 24 2
      4. Subnet mask – 2
      5. Click Next
    4. Add Exclusion and Delay – Click Next  2
    5. Lease Duration (Figure 182
      1. Limited to 8 hours 2
      2. Click Next
    6. Configure DHCP 2
      1. Select Yes
      2. Click Next
    7. Router (Default Gateway) (Figure 192
      1. IP address –
      2. Click Add
      3. Click Next
    8. Domain Name and DNS Servers – Click Next  2
    9. WINS Servers – Click Next  2
    10. Activate Scope
      1. Click Yes  2
      2. Click Next  2
    11. Click Finish
  6. Notice that Scope now appears under the DHCP>machine_name>IPv4 tree (Figure 20)
  7. Close the DHCP window

Phase V – Watch DHCP in Action

This lab is an opportunity for you to see these activities in action without the chaff that exists on an existing enterprise network.

  • DHCP automatically assigns an IP address to interfaces requesting one.
  • ARP is for interfaces that already have an IP address, but the interface needs to tell all of the other interfaces on the network.
  1. Navigate back to GNS3
  2. Start a Wireshark capture on the Server-Switch link
  3. Start PC1 and open its console
    1. Request a new IP address

      > ip dhcp

    2. Notice the four main DHCP packets being exchanged in Wireshark that were discussed in the previous chapter: Discover, Offer, Request, Accept
  4. Start PC2 and open its console
    1. Request a new IP address

      > ip dhcp

  5. Ensure that PC1 is able to ping PC2
  6. Congratulations! You now know how to configure a basic DHCP server on both Linux and Windows machines
End of Lab


4 screenshots are needed to receive credit for this exercise:

  • Wireshark – DHCP Packets for PC2
  • Wireshark – DHCP Packets for PC3
  • GNS3 Workspace with 2 PCs, switch, and DHCP server – all devices labeled with their IP addresses
  • Configuration settings of Windows Server DHCP


Assignment 1 – Combined network traffic watching

  • Turn off all devices
  • Replace the switch with a hub and reconnect all devices
  • Monitor any of the PCs with Wireshark and capture ARP, DHCP, and ICMP packets for all three PC’s as you turn devices back on
    • Screenshot of GNS3 environment with everything labeled
    • Screenshot of DHCP for one PC
    • Screenshot of ICMP for one PC

Assignment 2 – Reconfigure the DHCP server

  • Figure out the number of devices that can be attached to the switch
  • Generate a random IP address and choose a subnet that will allow the use of all the switch connections with as few wasted IP addresses as possible
  • Reconfigure the network to use these new network addresses
  • Reconfigure the DHCP settings to issue IPv4 address in this new space
    • Screenshot of the DHCP configuration
    • Screenshot of the GNS3 workspace
    • Screenshot of DHCP of one PC
    • Screenshot of ICMP of one PC
Figures for Printed Version
Picture of commands
Figure 4 – Select the ethernet option
Picture of commands
Figure 5 – Network Connections window
Picture of commands
Figure 6 – Ethernet Properties window
Picture of commands
Figure 7 – IPv4 Properties window
Picture of commands
Figure 8 – Before you begin screen
Picture of commands
Figure 9 – Installation type screen
Picture of commands
Figure 10 – Server Selection screen
Picture of commands
Figure 11 – Select add features
Picture of commands
Figure 12 – Click Complete DHCP configuration
Picture of commands
Figure 13 – Expand the local computer
Picture of commands
Figure 14 – Create a new scope
Picture of commands
Figure 15 – Welcome to New Scope Wizard Screen
Picture of commands
Figure 16 – Scope Name Screen
Picture of commands
Figure 17 – IP Address Range Screen
Picture of commands
Figure 18 – Lease Duration screen
Picture of commands
Figure 19 – Default Gateway screen
Picture of DHCP window showing completed scope
Figure 20 – Completed scope



Icon for the Creative Commons Attribution 4.0 International License

Mastering Enterprise Networks Copyright © 2024 by Raechel Ferguson is licensed under a Creative Commons Attribution 4.0 International License, except where otherwise noted.

Share This Book