Home » Cloud » [solved] how to migrate DHCP server from Windows server 2008 to Windows 2019

[solved] how to migrate DHCP server from Windows server 2008 to Windows 2019

With Windows server 2008 going to the end of support, it is critical that all Windows related services should now be moved to newest Windows 2019 server. one of the key service is DHCP and the process is very simple and I will walk you thru on moving the service to Windows 2019 server from Windows 2008 server step by step.

DHCP stands for Dynamic Host Configurations Protocol and is responsible for providing IP address to the devices.

Many corporate offices have primary and secondary DHCP servers responsible for providing IP addresses to all the devices in all the locations

The steps are very simple to migrate the configurations and active leases in few PowerShell commands. It is best to run these commands from the Windows 2019 server since it comes with the DHCP PowerShell module and Windows 2008 does not and you will need to install the PowerShell module

below are the only two commands that you need to run to export all the scopes and leases.

The “Export-DhcpServer” PowerShell command will export the configuraions and database and store on the configuration file on the local path that is defined.

Export-DhcpServer -File C:\DHCPDB\DHCPDB.xml -Leases -Force -ComputerName “name of the source computer” –Verbose

The “Import-DhcpServer” PowerSehll command will import all the configurations along with all the active leases

Import-DhcpServer -File C:\DHCPDB\DHCPDB.xml -BackupPath C:\DHCPDB\ -Leases -ScopeOverwrite -Force -ComputerName “destinametion computername” –Verbose

The -Verbose command at the end will display all the actions in the PowerShell windows with all the details.

You can see the output on the PowerShell console to see all the details

Leave a Reply

Your email address will not be published. Required fields are marked *

*
*