The easiest way to migrate from 2003 DHCP with split scopes to 2012 R2 DHCP with Failover, is to put in interim 2012 R2 split scope DHCP servers, then migrate them to final DHCP 2012 R2 servers with DHCP Failover. The reason for this is that the DHCP powershell cmdlets in 2012 R2 are superb! Really, its the only way.
In my case I have to move the DHCP servers off the subnet they are on, as well, plus they are on domain controllers, so the easiest way for me to do this is to create new DHCP servers, add ne IP Helpers on the switches and network devices, do the migration and disable old DHCP services as I go.
- Check the server option definitions and values are the same on the Source primary and secondary servers
- Use this script Compare DHCP Server Settings with PowerShell DHCP Cmdlets to check that your existing dhcp servers are actually like for like and knowing where they are different.
- Use this script Compare DHCP Scope Settings with PowerShell DHCP Cmdlets to check where you have scopes that are meant to be different and are not split scoped
You may of inherited a highly “non-standard” set of scopes between the servers. You know what admins are like….
The easiest way to do this is to do and export of your 2003 DHCP servers to a sandpit environment containing a DC and two 2102 R2 DHCP servers using this process Step-By-Step: Migration of DHCP from Windows Server 2003 to Windows Server 2012 . then you have two 2012 R2 DHCP servers configured exactly like your production environment
Interim 2012 R2 DHCP Servers
This is pretty straightforward, the only complicating bit is finding out where you use IP Helpers (aka DHCP Relay Agents ). To set up your interim 2012 R2 DHCP servers, you first need to add IP Helpers to your switches and other devices that relay DHCP offers across subnets.
My approach is to add all the interim and final DHCP IP helpers on all devices, then once I have fully migrated, remove surplus DHCP IP helpers. this is purely from a change control perspective (less Change Requests for me to do!)
Once the IP Helpers are set up, then you need to
- Export from each old 2003 DHCP server and Import into your new 2012 R2 DHCP server
- Shutdown and disable the old DHCP services on the old 2003 DHCP Servers
Final 2012 R2 DHCP Servers – Migrate the Server options
Because you will be building the final servers from scratch, you need to ensure that you have migrated over any custom server option definitions and values.
DHCP server options comprise two parts, the definition of the option and the value(s) in that option
Definitions are normally Added/Edited via the GUI under “set predefined options” (Right click on IPV4)
Get the server option definitions from the primary source server
$a = Get-DhcpServerv4Optiondefinition -computername 2012-dhcp1
Set the server option definitions from the source server to the primary destionation server
$a | set-DhcpServerv4Optiondefinition -computername 2012-dhcp3
Set the server option definitions from the source server to the primary destination server
$a | set-DhcpServerv4Optiondefinition -computername 2012-dhcp4
Values are normally Added/Edited via the GUI under “configure options” (Right click on server options under IPV4)
To get the server options from the Source server
$b = Get-DhcpServerv4OptionValue -computername 2012-dhcp1
Set these options on the Primary destination server
$b | Set-DhcpServerv4OptionValue -computername 2012-dhcp3
Set these options on the Secondary destination server
$b | Set-DhcpServerv4OptionValue -computername 2012-dhcp4