DHCP Post-Installation wizard with PowerShell?

CptRetro 501 Reputation points
2021-03-01T08:14:51.267+00:00

Hello all,

With the following lines I have, for test purposes, installed a DHCP server on a domain controller via PowerShell.

Install-WindowsFeature DHCP -IncludeManagementTools
Add-DhcpServerV4Scope -Name lab -StartRange 10.10.10.50 -Endrange 10.10.10.100 -State Active -PassThru
Add-DhcpServerInDC -DnsName lab.lcl -IPAddress 10.10.10.10

After reboot I noticed that the post-installation wizard is still active and wanted an final configuration. How can I automate this wizard with PowerShell?

Cheers

Windows DHCP
Windows DHCP
Windows: A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.DHCP: Dynamic Host Configuration Protocol (DHCP). A communications protocol that lets network administrators manage centrally and automate the assignment of Internet Protocol (IP) addresses in an organization's network.
1,034 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,449 questions
0 comments No comments
{count} votes

Accepted answer
  1. CptRetro 501 Reputation points
    2021-03-01T12:00:13.403+00:00

    Got it

    • Notify Server Manager that post-install DHCP configuration is complete (Optional)

      Set-ItemProperty –Path registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\ServerManager\Roles\12 –Name ConfigurationState –Value 2

    https://learn.microsoft.com/en-us/windows-server/networking/technologies/dhcp/dhcp-deploy-wps


0 additional answers

Sort by: Most helpful