|
|
|
#1 |
|
Messages: n/a
Hébergeur: |
The reverse zone for an address range was not created at the start. I need to
programatically update the reverse zone if possible from the existing forward zone, any suggestions? |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
"Bob" <Bob@discussions.microsoft.com> wrote in message news:06AF6421-369C-4F91-BF13-1F9AD385D78E@microsoft.com... > The reverse zone for an address range was not created at the start. I need > to > programatically update the reverse zone if possible from the existing > forward > zone, any suggestions? There is NO relationship between forward and reverse zones in DNS itself -- the only such relationship is in the minds of admins like us. So you will need to script this if you wish to do something like this, perhaps using DNSCmd to first dump the list of forward records and then (after any post-processing) using that list to script in the changes to the reverse zone. You can use /enumrecords to get the list of records: dnscmd /enumrecords learnquick.com . (that's a "."-dot on the end there since you must give the starting node) Problem is this gets ALL records so you have to send it through Grep, Awk, Sed, Perl, etc or edit the result by hand: I don't usually use FindStr (prefering a good Grep or Perl but I have approximated the FindStr to strip the unnecessary lines (only close because FindStr is giving me unpredictable results): dnscmd /enumrecords learnquick.com . | findstr /r "^[a-z].* +A +[0-9.]+$" Once you have the list of records you can pump them through a DNSCmd /RecordAdd with one (or two) for..in..do loops. You will need two if you don't have another way to differentiate dynamic records (with an Aging: parameter) from Static records AND if you want to check both. -- Herb Martin, MCSE, MVP http://www.LearnQuick.Com (phone on web site) |
|
![]() |
| Outils de la discussion | |
|
|