How To: Migrate DHCP from Server 2008 R2 to Server 2012/Server 2016

How To: Migrate DHCP from Server 2008 R2 to Server 2012/Server 2016

Tonight, I was tasked with migrating DHCP from one server running Windows Server 2008 R2 to another, running Windows Server 2012 R2. This will be a quick entry, lacking any especially descriptive screenshots.

Step one – backup the existing DHCP configuration:

The first step is to take an entire backup of the existing DHCP configuration, on the server we are decommissioning. To do this, open the DHCP management console. Right click on your DHCP server, and choose “Backup…”

Pick a location, and save your backup here.

Step two – export configuration to a format that is importable:

Now that we have taken a backup of our DHCP server, in case anything goes wrong, we need to go ahead and export our server’s configuration, including things such as our leases, our reservations and even the definition of our scope. In order to do this, in a command prompt, enter the below:

netsh dhcp server export C:\temp\dhcp-export.txt

You have now successfully exported your DHCP configuration in a format we will use to setup our new server.

Step three – install the DHCP role on the new server:

In order to import the now exported config, we must have the role ready on the new server.
Go ahead and install the DHCP role from the Server Manager on the new server.

Step four – import our DHCP configuration in to the new server:

Now we have our config, we must import it in to the new server.
First, copy it across to the new server, allowing us to reference it on the local machine. I like to use the same location on the second server.

Once you have copied the file across, log on to the new server and enter the below, in a command prompt:

netsh dhcp server import C:\temp\dhcp-export.txt

Now open your DHCP management console, right click on the server, and choose “Authorize…”

Step five – test our handy work:

Now that we’ve supposedly imported the configuration, and everything has gone smoothly, we want to confirm our configuration has truly imported, and is correct. Launch your DHCP management console and take a look at your settings, confirming they are correct… viola!

Step six – temporarily or permanently disable the old DHCP server:

Everything has now successfully transferred, and we have confirmedĀ  our settings are all correct on the new server. There is one thing left we must do – disable the old server!=

Personally, I like to leave the old server in tact as of this moment, by simply stopping and disabling the service. You, however, may prefer to completely decommission the old server, right away.

If you wish to immediately and permanently decommission your old server, launch the DHCP management console on the old server and, from the menu, click on “Unauthorize”.

0 comments