Re: Importing dns records
- From: "Joe Cormane" <nobody@xxxxxxxxxxx>
- Date: Tue, 10 Jul 2007 11:50:24 -0500
No problem. It was in the earlier post. Either way, I created a text file
that is formatted like this:
dallasCLR01 xxx.xxx.xxx.101 101
dallasclr02 xxx.xxx.xxx.102 102
dallasclr03 xxx.xxx.xxx.103 103
dallasclr04 xxx.xxx.xxx.104 104
dallasclr05 xxx.xxx.xxx.105 105
dallasclr06 xxx.xxx.xxx.106 106
dallasclr07 xxx.xxx.xxx.107 107
dallasclr08 xxx.xxx.xxx.108 108
dallasCLR10 xxx.xxx.xxx.110 110
dallasCLR11 xxx.xxx.xxx.111 111
dallasclr12 xxx.xxx.xxx.112 112
dallasCLR12 xxx.xxx.xxx.112 112
dallasclr9 xxx.xxx.xxx.109 109
Column 1 is the name, column 2 is the IP and column 3 is for the reverse DNS
name. Each column is separated by a space.
"Ghealdan" <Ghealdan@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:FB6D9E5F-5583-4E80-95AC-0FA003A1CD91@xxxxxxxxxxxxxxxx
Thanks again I appreciate your help. I don't see the attached file in the
post.
"Joe Cormane" wrote:
That should not be necessary. All you'd really need to do is either
create
a batch file for each of those commands to iterate through the contents
of
the file or combine the command to something like this:
for /f "tokens=1,2,3" %%1 in (printers.txt) do
@dnscmd <DOMAIN CONTROLLER> /RecordAdd <FORWARD ZONE> %%1 A %%2
@dnscmd <DOMAIN CONTROLLER> /RecordAdd <REVERSE ZONE> %%3 PTR
%%1.<DOMAIN>
then use those in a single batch file. As long as you have the csv
formatted like the one i attached then saved as a tab delimited (or space
delimited) text file you should be set. Test, of course, with a single
entry first!
"Ghealdan" <Ghealdan@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:3AE1C939-CDA1-4D9B-A235-26A4893F0B11@xxxxxxxxxxxxxxxx
Thanks for the info Joe. So do I need these two lines for every dns
entry
I
want to import from my csv file?
"Joe Cormane" wrote:
I actually did this fairly recently for some printers. The best way
to
do
it is have a tab-delimited text file (like the one attached) and run
the
following commands from a batch file (if running interactively remove
one
%
from each of the %%:
for /f "tokens=1,2,3" %%1 in (printers.txt) do @dnscmd <DOMAIN
CONTROLLER>
/RecordAdd <FORWARD ZONE> %%1 A %%2
for /f "tokens=1,2,3" %%1 in (printers.txt) do @dnscmd <DOMAIN
CONTROLLER>
/RecordAdd <REVERSE ZONE> %%3 PTR %%1.advisors.hal
The numbers represent the column numbers (e.g. %%1 is column 1 and so
on).
Please let us know if that helps you. I think you'll find DNSCMD very
useful.
Joe Cormane
Senior Network Engineer
Hudson Advisors, LLC.
"Ghealdan" <Ghealdan@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:0A478940-CEF1-4C5C-B5F3-916680E660E8@xxxxxxxxxxxxxxxx
I have a *.csv file of DNS records I pulled from another system that
I
would
like to import into my Server 2003 DNS database. Is there anyway to
do
this?
.
- Follow-Ups:
- Re: Importing dns records
- From: Ghealdan
- Re: Importing dns records
- From: Ghealdan
- Re: Importing dns records
- References:
- Re: Importing dns records
- From: Joe Cormane
- Re: Importing dns records
- From: Ghealdan
- Re: Importing dns records
- Prev by Date: Re: Importing dns records
- Next by Date: Re: DNS and AD creation question
- Previous by thread: Re: Importing dns records
- Next by thread: Re: Importing dns records
- Index(es):
Relevant Pages
|