Solved

export forwarders

Posted on 2010-08-26
23
3,050 Views
Last Modified: 2012-05-10
Hi Experts,
I have a new DNS running on win2008.
On the old DNS in win2003r2 I have dns forwarders installed.
is there a possibility to export the forwarders and import them to my new DNS server ?
0
Comment
Question by:Eprs_Admin
  • 12
  • 11
23 Comments
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

Could do. I assume you have quite a lot of them then? And I assume you're talking about conditional forwarders?

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
yes right.
I have a lot of them.
In win2003 its called forwarders, when you select the DNS server in DNS window.

In 2008 when I open DNS and select the server, I have FORWARDERS and a folder called CONDITIONAL FORWARDERS.

Whats the difference ?
0
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

Nothing more than presentation. They simply decided that it should go in a different place in the GUI.

I have a toolset for this kind of thing, I just need to adjust it slightly so it can do this neatly. I'll be right back :)

Chris
0
 
LVL 70

Accepted Solution

by:
Chris Dent earned 500 total points
Comment Utility

Okay so, it's easy, but you need these two:

PowerShell 2: http://support.microsoft.com/kb/968930/en-gb
DnsShell (DNS Management Module for PowerShell): http://code.msdn.microsoft.com/dnsshell/

The first will be pre-installed if you have 2008 R2, otherwise you will need to upgrade PowerShell 1 to PowerShell 2 (PS 1 is pre-installed on 2008).

DnsShell is my management module, once you have it all you need do is this in the PowerShell prompt:


Import-Module DnsShell
$OldServer = "YourOldDnsServer"
$NewServer = "YourNewDnsServer"

Get-DnsZone -ZoneType Forwarder -Server $OldServer | New-DnsZone -Server $NewServer


If you want to test it on one use:


Get-DnsZone whateverzone -Type Forwarder | New-DnsZone -Server $NewServer


And please let me know if you have any questions about any of this.

HTH

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
I don't know how to export the forwarders.
Can you explain it in detail maybe ?
0
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

This pulls the Forwarders from the specified server:


Get-DnsZone -ZoneType Forwarder -Server "ServerName"


Piping the output from that into the New-DnsZone CmdLet will have it set up the forwarders (in this case) on the other server. The New-DnsZone CmdLet accepts input like this:


New-DnsZone -ZoneName "SomeZone.com" -ZoneType Forwarder -MasterServer "1.2.3.4", "2.3.4.5"


However, since I'm suggesting you use the piped version you don't need to type in each of the parameters.

You can use other tools such as dnscmd if you prefer, but it's a lot more effort to get from the output there to creation of the forwarders on the other server. To extract them using dnscmd you would use:


dnscmd OldServer /EnumZones /Forwarder


You might pull apart the output from that in Excel (or similar) and construct the commands to create the forwarders on the new server using:


dnscmd NewServer /ZoneAdd Name /Forwarder MasterIP1, MasterIP2


All entirely possible, but so much work :)

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
ok, what I have to install on the old server win2003 ?
And what on the new server win2008 ?
0
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

You can install PowerShell 2 and download the module above on either server, or your workstation for that matter. Doesn't matter where you put it really.

However, you only need to install it in one place. My personal preference is to do stuff like this on my workstation, leaving my servers nice and clean :)

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
I cannot download the module.

Error symbol      The Windows Live Network is unavailable from this site for one of the following reasons:

    * This site may be experiencing a problem
    * The site may not be a member of the Windows Live Network

You can:

    * You can sign in or sign up at other sites on the Windows Live Network, or try again later at this site.
0
 

Author Comment

by:Eprs_Admin
Comment Utility
Do you have another solution to get the module ?
0
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

Sure, you can download it from my site here:

http://www.indented.co.uk/wp-content/uploads/2010/08/DnsShell.zip

Chris
0
VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

 

Author Comment

by:Eprs_Admin
Comment Utility
Where is module folder to put the module ?
Cannot import the module.
0
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

Under "My Documents" / "Documents" create a folder called "WindowsPowerShell", then beneath that another called "Modules". The zip file should be exported there, including the DnsShell folder.

Restart the PowerShell prompt and it should let you use Import-Module.

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
Please can you exactly write down, what I have to enter in the dnsshell ?
Now its not working:

Comand after comand please.
0
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

Exactly where is it breaking? Because *everything* you need to type is above. If it's failing I need to know how.

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
scripts are not allowed on my system.
0
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

Ahh okay, in that case run:


Set-ExecutionPolicy RemoteSigned


It's because the module is not signed with a certificate, I'll get around to it one day.

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
ok thanks.
But I think I found another simpler way.
We just extracted the registry from the old zones to the new server.

Now we have all entries in the conditional forwarders.
But what are the difference from the all old forwarders to the new ? Because in 2008 I have both , FORWARDERS and CONDITIONAL FORWARDERS ?
0
 
LVL 70

Assisted Solution

by:Chris Dent
Chris Dent earned 500 total points
Comment Utility

Forwarders are Global, Conditional Forwarders are a type of zone.

2003 doesn't really differentiate between the two, putting everything under the Forwarders tab. 2008 does, it maintains separate areas for each as you've seen.

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
But do think it is ok to have now all in conditional forwarders and not in global ?

0
 

Author Comment

by:Eprs_Admin
Comment Utility
Here is my solution for it :

How to migrate DNS forwarders from Win2003 to Win2008      

Source server:
Open application registry editor "regedit"
Go to hive key" HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\DNS Server\Zones
Then go to the top menu: "File, Export

Save the file temporay location.

Target server:
Open application registry editor "regedit"
First nake a FULL backup of the actual registry
Then go to the top menu: "File, Import
Select the file that you exported of the source server.
Then restart server.
0
 
LVL 70

Expert Comment

by:Chris Dent
Comment Utility

> But do think it is ok to have now all in conditional forwarders and not in global ?

Yes. As I said above it's a presentation change, they changed how it looked, it doesn't effect how it actually works.

Chris
0
 

Author Comment

by:Eprs_Admin
Comment Utility
Ok my friend, then all is solved now !
Thanks a lot.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This article is intended as an extension of a blog on Aging and Scavenging by the MS Enterprise Networking Team. In brief, Scavenging is used as follows: Each record in a zone which has been dynamically registered with an MS DNS Server will have…
A Cisco router can be configured as a DHCP Server. There are advantages and disadvantages in making your Cisco router work as DHCP Server. Almost all the features for windows DHCP can be configured on Cisco-based DHCP server. Some of the features me…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now