Install and configure DHCP Server on Windows Server (2024)

  • Article

Applies to: Windows Server 2022, Windows Server 2019, Windows Server 2016

This quickstart shows you how to install a Dynamic Host Configuration Protocol (DHCP) server onWindows Server. You'll install the DHCP Server role, authorize the server in your Active Directorydomain, and configure a scope to automatically assign DHCP IP addresses and options to IPv4 DHCPclients.

Prerequisites

Before you can install your DHCP server, you must meet the following prerequisites:

  • A computer running a supported version of Windows Server.
  • A static IPv4 address.
  • An IP address range for your DHCP scope.
  • An account that's a member of the Administrators group, or equivalent.

Install the DHCP Server

Installing the DHCP Server involves adding the DHCP Server role to an existing Windows Server server.

To install the DHCP Server role as a standalone server, perform the following steps:

  • PowerShell
  • GUI

Here's how to install DHCP using the Install-WindowsFeature command.

  1. Run PowerShell on your computer in an elevated session.

  2. Run the following command:

    Install-WindowsFeature DHCP -IncludeManagementTools

The installation doesn't require a reboot.

Configure DHCP server

After you have successfully installed the DHCP Server role, you need to authorize and configure your DHCP server.

Authorize the DHCP server in Active Directory

If you're installing DHCP in a domain environment, you must perform the following steps to authorize the DHCP server to operate in the domain.

Note

Unauthorized DHCP servers that are installed in Active Directory domains can't function properly and don't lease IP addresses to DHCP clients. The automatic disabling of unauthorized DHCP servers is a security feature that prevents unauthorized DHCP servers from assigning incorrect IP addresses to clients on your network.

To authorize your DHCP server in a domain environment:

  • PowerShell
  • GUI
  1. Run the following command to add the DHCP server to the list of authorized DHCP servers in Active Directory.

    Note

    If you don't have a domain environment, don't run this command.

    Add-DhcpServerInDC -DnsName DHCP1.corp.contoso.com -IPAddress 10.0.0.3
  2. To verify that the DHCP server is authorized in Active Directory, run the following command:

    Get-DhcpServerInDC

    The following example shows the output you should see in Windows PowerShell.

    IPAddress DnsName--------- -------10.0.0.3 DHCP1.corp.contoso.com

For more information about these commands, see the following articles:

  • Add-DhcpServerInDC
  • Get-DhcpServerInDC

Configure an IPv4 scope

After you have successfully authorized your DHCP Server, you can proceed to create a new DHCP scope.Scopes are used to indicate the range of IP addresses for your DHCP server and its clients. To learnmore about planning your scope ranges, see DHCP scopesfor guidance.

To create a new IPv4 DHCP scope, select the relevant method and follow the steps.

  • PowerShell
  • GUI

Here's how to create a new scope using the Add-DhcpServerv4Scope PowerShell command.

  1. Run PowerShell on your computer in an elevated session.

  2. To configure a new DHCP scope named Contoso network with a range from 10.10.10.100 to 10.10.10.200 and a subnet mask of 255.255.255.0, run the following command.

    Add-DhcpServerv4Scope -Name "Contoso network" -StartRange 10.10.10.100 -EndRange 10.10.10.200 -SubnetMask 255.255.255.0

Managing scope options

After configuring your new scope, you can manage scope options using either the DHCP console or PowerShell.

  • PowerShell
  • GUI

You can modify DHCP scope options using PowerShell with the Set-DhcpServerv4OptionValue cmdlet. For example, to set the DNS server option for the scope 192.168.15.0 and set the DNS servers to 192.168.15.10 and 192.168.15.11, run the following command:

Set-DhcpServerv4OptionValue -ScopeId 192.168.15.0 -OptionId 6 -Value "192.168.15.10", "192.168.15.11"

Managing reservations

With client reservations, you can reserve an IP address for permanent use by a DHCP client. Reservations are stored using a network interface card's (NIC) MAC address and ensure that the DHCP server exclusively leases a specific IP address to a specific MAC address.

  • PowerShell
  • GUI

You can create reservations using the Add-DhcpServerv4Reservation PowerShell cmdlet. For example, to add a reservation to a DHCP scope with a scope ID of 192.168.15.0, an IP address of 192.168.15.100, and the MAC address 00-11-22-33-44-55, run the following PowerShell command:

Add-DhcpServerv4Reservation -ScopeId 192.168.15.0 -IPAddress 192.168.15.100 -ClientId "00-11-22-33-44-55" 

Managing exclusions

Here's how to manage exclusion ranges in DHCP server.

  • PowerShell
  • GUI

You can run the Add-DhcpServerv4ExclusionRange cmdlet to add an exclusion range to a DHCP scope using PowerShell. For example, to add the exclusion range 192.168.15.1 to 192.168.15.10 to the scope 192.168.15.0, run the following command:

Add-DhcpServerv4ExclusionRange -ScopeId 192.168.15.0 -StartRange 192.168.15.1 -EndRange 192.168.15.10

Next steps

  • DHCP Basics
  • DHCP Subnet selection options
Install and configure DHCP Server on Windows Server (2024)
Top Articles
What is the best blockchain for smart contracts and why?
What Is a Hard Inquiry? - NerdWallet
Www.mytotalrewards/Rtx
Mackenzie Rosman Leaked
St Petersburg Craigslist Pets
His Lost Lycan Luna Chapter 5
Apply A Mudpack Crossword
Lowes 385
Moviesda Dubbed Tamil Movies
What Was D-Day Weegy
LA Times Studios Partners With ABC News on Randall Emmett Doc Amid #Scandoval Controversy
[PDF] INFORMATION BROCHURE - Free Download PDF
Trini Sandwich Crossword Clue
Grace Caroline Deepfake
Elizabethtown Mesothelioma Legal Question
ᐅ Bosch Aero Twin A 863 S Scheibenwischer
Sivir Urf Runes
111 Cubic Inch To Cc
NHS England » Winter and H2 priorities
Walmart stores in 6 states no longer provide single-use bags at checkout: Which states are next?
How to Create Your Very Own Crossword Puzzle
Vrachtwagens in Nederland kopen - gebruikt en nieuw - TrucksNL
Nearest Walgreens Or Cvs Near Me
Tyler Sis University City
Apple Original Films and Skydance Animation’s highly anticipated “Luck” to premiere globally on Apple TV+ on Friday, August 5
Lisas Stamp Studio
Accuweather Minneapolis Radar
Hellraiser 3 Parents Guide
Goodwill Of Central Iowa Outlet Des Moines Photos
Vht Shortener
What we lost when Craigslist shut down its personals section
Miles City Montana Craigslist
Kamzz Llc
Mrstryst
Craigslist Maryland Baltimore
Urban Blight Crossword Clue
Matlab Kruskal Wallis
Nacho Libre Baptized Gif
Obsidian Guard's Skullsplitter
The 50 Best Albums of 2023
Smith And Wesson Nra Instructor Discount
Thanksgiving Point Luminaria Promo Code
Jason Brewer Leaving Fox 25
Janaki Kalaganaledu Serial Today Episode Written Update
Sams Gas Price Sanford Fl
Dontrell Nelson - 2016 - Football - University of Memphis Athletics
3500 Orchard Place
Euro area international trade in goods surplus €21.2 bn
Jeep Forum Cj
Call2Recycle Sites At The Home Depot
7 National Titles Forum
Latest Posts
Article information

Author: Gov. Deandrea McKenzie

Last Updated:

Views: 6367

Rating: 4.6 / 5 (66 voted)

Reviews: 81% of readers found this page helpful

Author information

Name: Gov. Deandrea McKenzie

Birthday: 2001-01-17

Address: Suite 769 2454 Marsha Coves, Debbieton, MS 95002

Phone: +813077629322

Job: Real-Estate Executive

Hobby: Archery, Metal detecting, Kitesurfing, Genealogy, Kitesurfing, Calligraphy, Roller skating

Introduction: My name is Gov. Deandrea McKenzie, I am a spotless, clean, glamorous, sparkling, adventurous, nice, brainy person who loves writing and wants to share my knowledge and understanding with you.