How to move DHCP from one server to another DHCP server
Today at the office , I was decommissioning one of our older Windows server 2008 machines and upgrading it to Windows 2016. I was initially a little worried, seeing as this server ran a lot of key roles, such as DHCP, DNS, Active Directory, and print services. As I was migrating the DHCP role, I wondered if there was a simple way of exporting all of the settings, such as DHCP scope and reserved IP addresses. Turns out there was, and it went off without a hitch.
This is how to do it
- Log on to the existing DHCP server.
- Open a command prompt as an administrator.
- Type netsh dhcp server export dhcp.txt all, and then press ENTER.
- Install the DHCP role on the new (2016) server using Server Manager.
- Copy the exported DHCP text file to the desktop of the new DHCP server.
- Verify that the DHCP service is installed and started on the new DHCP server.
- Do not add any other settings at this time
- Open a command prompt as administrator on the new server.
- Type netsh dhcp server import dhcp.txt all, and then press ENTER
- Open DHCP console on the new server. And in the console tree select Authorize
Check to make sure that your new DHCP server has all of the same settings, options, scopes, and reservations set as the old one. If done correctly, everything should have been brought over. I was pretty impressed as to how well this worked and just how seamless it truly was.
If your old DHCP server is in the same network/subnet as the new DHCP server, you’ll notice that the old DHCP server has been de-authorized automatically. This is to prevent two DHCP servers from handing out conflicting addresses.