Installing DHCP on Windows Server Core using the command line

 In Server Core, Windows

Installing DHCP on Windows server core using the command line

During the building of server core instances of Windows server, you might want to install DHCP Server, especially if you have just built a domain controller. As the title states “Installing DHCP on Windows Server Core using the command line”.

To install DHCP Server on a server using the command line

Code

start /w ocsetup DHCPServerCore

and press Enter.

To uninstall DHCP Server on a server using the command line

Code

start /w ocsetup DHCPServerCore /uninstall

and press Enter.

The service is automatically set to disabled, so you’ll not be able to start it. Here’s how to change it’s default state and then start the service

To change the DHCP Server service to auto start on a server using the command line

Code

sc config dhcpserver start= auto

and press Enter.

Now you can start the service

To start the DHCP Server service from the command line

Code

net start dhcpserver

and press Enter.

At this point you could carry on configuring it from the command line, but you could start to drive yourself a little crazy with all the commands needed. I generally make sure I have the DHCP Role Administration feature installed on a machine nearby, which DOES have a GUI, and then I run through the remainder of the config from here.

Enjoy!

Recommended Posts

Leave a Comment

Contact Us

We're not around right now. But you can send us an email and we'll get back to you, asap.

Not readable? Change text. captcha txt

Start typing and press Enter to search

Choosing the right storage for your virtual platform