• Renan Antonio Rodrigues

How to convert secondary DNS zone into AD-integrated zone

If you are looking for a guide showing how to convert a secondary DNS zone into AD-Integrated zone, this post shows how to do that in an easy way.


1 - Export the zone information from the SOA (the authoritative dns server for the zone, which can be any dns server in an ad-integrated zone):


DnsCmd dc01.contoso.local /ZoneExport contoso.local contoso.local.copy.bak


This will export the zone DNS from the SOA, to the folder %SystemRoot%\System32\DNS\


This first step is to make sure you will have a reliable backup of the zone you will convert.


2 - Now, back to server which has the secondary zone (I suppose you are connected in a different domain too. Be aware all procedure below must be done in the target servers of the the target domain, here in this example domainAZ , not in the source domain contoso.local)


Convert the secondary zone (contoso.local) in one of the DNS servers of domainAZ.local, to a primary zone:


DnsCmd dc12.domainAZ.local /ZoneResetType contoso.local /Primary /File contoso.local.dns


This command will convert it to a primary zone and create a dns file at %SystemRoot%\System32\DNS\


3 - Now, you must delete the secondary zone from all other DNS servers in the target domain domainAZ.local


DnsCmd dc18.domainAZ.local /ZoneDelete contoso.local

DnsCmd dc39.domainAZ.local /ZoneDelete contoso.local


4 - Next, back to DNS server which has the primary zone (the only one at this moment, on the target domain domainAZ.local ok?), and remove all old NS records.


At this part, you will see the name of DNS servers from the source domain contoso.local


As this zone is no longer updated from DNS servers of contoso.local, and the DNS servers of domainAZ.local will become the authoritative one, you can delete it using the command:


dnscmd dc12.domainAZ.local /RecordDelete contoso.local @ NS dc01.contoso.local


5 - Finally, convert the now primary zone in to an AD-integrated zone:


DnsCmd dc12.domainAZ.local /ZoneResetType contoso.local /DsPrimary


The zone will be now replicated to all domain controllers in domainAZ.local. If you want accelerate this process, use the following command: repadmin /syncall /AdeP


For any doubts or suggestions, please leave a comment below.

Follow me

© 2023 by Nicola Rider.
Proudly created with
Wix.com
 

  • Branca Ícone LinkedIn