Transfer scope to new server
Export Configuration from Old Server
-
Open an elevated PowerShell prompt on the new server.
-
Run the export command to generate an XML file of your scopes and leases:
Export-DhcpServer -ComputerName "OldServerName" -Leases -File "C:\dhcpconfig.xml" -Force -
Copy the exported XML file (dhcpconfig.xml) to the new server.
Import Configuration to New Server
-
Stop the DHCP service on the new server or ensure scopes remain disabled initially to prevent conflicts.
-
Open PowerShell on the new server and run the import command:
Import-DhcpServer -File "C:\dhcpconfig.xml" -BackupPath "C:\backup\dhcpbackup.xml" -
Authorize the new DHCP Server in Active Directory and deauthorize the old server.
-
Enable/start the DHCP service on the new server and verify client connectivity.