How to Migrate Active Directory,DNS and DHCP to a New Server.




How to migrate active directory,DNS and DHCP to a new server

From this article, you can study How to migrate active directory,DNS and DHCP to a new server. Migrating active directory and other services from old server to new server is a complicated process. From windows server we can use dcpromo to facilitate the migration process. We can use dcpromo to create a new AD domain controller and it will replicates the settings of the old domain controller. After replication we can manually transfer DHCP and DNS datas. Please carefully follow the below steps to transfer active directory,DNS and DHCP to a new server.

  • From new server, do to run and type “Dcpromo” and press enter. It will open AD installation wizard.
  • Check “Use Advanced Mode Installation” and then click ” and click on next button. Again click on next button.
  • Click on  “Existing Forest” from Choose a Deployment Configuration window then tick radial button “Add a Domain Controller to an Existing Domain.” and click on next button.

Choose a Deployment Configuration screen theonlinetutorials

  • Enter proper domain name and click on  “My Current Logged on Credentials,” or select “Alternate Credentials” and type the administrative login for the account. Click on “Set.”  and Click on  “Next.” button.

  • Enter the log on information for member of the enterprise administrators or domain administrators group. and click on the next button.
  • From here, select the destination domain and click on “Next.” button and select a site for the new domain controller and click on “Next.” button.
  • From this window Check “DNS Server” and then click “Next.” button and Click on “Replicate Data Over the Network from an Existing Domain Controller.” and Click on  “Next” button.
  • From this window, you have to click on “Use This Specific Domain Controller” option and then select the source server. After this click on next button.
  • From this window you have to enter the destination folders for the database, log and SYSVOL files creation, or use the default folders and click on the next button.
  • You need to create a password for the administrative account to be used when starting the domain controller from Directory Services Restore Mode and click on the next button. From here check all the settings and click on the next button.
  • Press the finish button to migrate the domain controller to the destination server.

DNS configuration

  • Log on the source server and go to the command prompt and type “dnscmd /EnlistDirectoryPartition” to determine which partitions are running on the source and target servers.
  • Enter the following commands to the command prompt to get ready DNS migration:

net stop “DNS SERVER”
dnscmd /EnlistDirectoryPartition
reg export HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\DNS\Paraments C:\Windows\System32\DNS\service.REG
reg export “HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\DNS Server” C:\Windows\System32\DNS\software.REG
xcopy c:\windows\system32\dns <target> /s
net start “DNS SERVER”

Replace “<target>” with the full file path linking to the network share or pendrive. Press “Enter” after each command.

  • Log on to destination server and open command prompt and type this command net stop “DNS SERVER”.
  • Transfer the information file from the network share or pendrive to following destination

c:\windows\system32\DNS.

  • Double click on the REG files to register the data stored to each file.
  • Go to the command prompt and enter below command on source server.

net start “DNS SERVER”

  • Open windows power shell and type following commands. You need to press enter after typing each commands.

Stop-Service DHCPserver
Add-PSSnapin Microsoft.Windows.ServerManager.Migration

Note: To open windows power shell, Click on start button and go to run and type powershell press enter.

  • Execute command “Export-SmigServerSetting” to populate DHCP  data and create a svrmig.mig file.
  • Execute “Export-SmigServerSetting -featureID DHCP -User All -Group -IPConfig -path <storage> -Verbose” — without quotes — in PowerShell.

Note: You need to replace “<storage>” with the file path linking to a network share orpen drive.

  • Enter the following to remove DHCP authorization from the source server:

netsh DHCP delete server <fqdn> <address>

Replace “<fqdn>” with the fully qualified domain name associated with the source server, and “<address>” with the server IP address.

  • Open power shell again and on the destination server and run the below command:-featureid DHCP -User All -Group -IPConfig <type>
    -SourcePhysicalAddress <source adapter 1>,<source adapter 2>
    -TargetPhysicalAddress <destination adapter 1>,<destination adapter 2>
    -Force -path <storage> -Verbose
  • Replace “<type>” with All, Global or NIC. Global imports Windows IP settings, NIC imports IP settings for specific network adapters, All imports IP settings for both network adapter and Windows IP settings. Replace “<source adapter 1>” with the MAC   address associated with the first source network adapter; replace <destination adapter 1>” with the media access address associated with the first destination adapter. Need to commas separate each subsequent adapter.
  • Enter the below commands after migrating the IP configurations:

Start-Service DHCPServer
netsh DHCP add server <fqdn> <address>

Replace “<fqdn>” with the computername of the destination server, and “<address>” with the server IP.

Yes, you successfully finished the migration of active directory,DNS and DHCP.



Print Friendly

Leave a Reply