How to Migrate DHCP Scopes from Windows 2008/Windows 2012 to Windows 2019 Server using PowerShell

This is tricky and sometime GUI backup and restore may give you errors like function not supported or cannot import the DataBase.

Using this powershell method, there is no error and using verbose logging you can also see the logs at the same time.

Use below PowrShell to export the scopes from old server to new server.

Export-DhcpServer -File C:\temp\DHCPDB.xml -Leases -Force -ComputerName fra-winapp01.prg.ori.local –Verbose

then move the XML file exported at the c:\temp to new dhcp server.

Then run the below command to import the dhcp scopes to new server.

Import-DhcpServer -File C:\temp\DHCPDB.xml -BackupPath C:\temp\ -Leases -ScopeOverwrite -Force -ComputerName dhcpprg1.prg.ori.local –Verbose

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.