I can use tools like dnslint to indentify errors; however, I wonder if
someone has a slick hack (script, regex) that can be utilized to run
through and reformat the zonefiles (forward and reverse) to get them in
order and tidy.
Thanks.
Load the file into a server and try dig @server <zone> axfr. The
AXFR output will be a nearly correctly formatted file. The gotcha is
the last record - the terminating SOA RR. Remove that plus the other
commented ("^;;") lines and you will have a zonefile.
'Course, you may not be happy with that format, but it is a "correct" format.
--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Edward Lewis +1-571-434-5468
NeuStar
Dessert - aka Service Pack 1 for lunch.
If you can afford a spare DNS-server, serve the file on one server
and slave it to the other.
The slave file is perfect and looks better than "dig axfr".
No need to delete the 2nd SOA entry.
If you can slave on your master then you can slave directly to
the place you need them. Just turn slave into master when you
are done and comment or delete the "masters" entry.
Kind regards
Peter and Karin
Forrest Aldrich wrote:
| I've inherited a slew of DNS zonefiles which need to be cleaned up -
| mostly formatting.
|
| I can use tools like dnslint to indentify errors; however, I wonder if
| someone has a slick hack (script, regex) that can be utilized to run
| through and reformat the zonefiles (forward and reverse) to get them in
| order and tidy.
|
|
| Thanks.
|
|
- --
Peter and Karin Dambier
Cesidian Root - Radice Cesidiana
Rimbacher-Strasse 16
D-69509 Moerlenbach-Bonsweiher
+49(6209)795-816 (Telekom)
+49(6252)750-308 (VoIP: sipgate.de)
mail: pe...@peter-dambier.de
mail: pe...@echnaton.serveftp.com
http://iason.site.voila.fr/
https://sourceforge.net/projects/iason/
http://www.cesidianroot.com/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQFFr7icPGG/Vycj6zYRAsBtAJoC3NpQvp2UZ8wn4jkdrJBI+6ucrwCfX9Gr
yl1KrGpSBqHtb263mlbsmhI=
=dzUT
-----END PGP SIGNATURE-----
> I've inherited a slew of DNS zonefiles which need to be cleaned up -
> mostly formatting.
>
> I can use tools like dnslint to indentify errors; however, I wonder if
> someone has a slick hack (script, regex) that can be utilized to run
> through and reformat the zonefiles (forward and reverse) to get them in
> order and tidy.
>
Or you can try to use "named-checkzone" with -D option (Dump zone file in
canonical format) and -o <filename> option (Write zone output to
<filename>) to get the same result.
Kind Regards
>
> Thanks.
>
>
>
--
Sebastian E. Castro Avila seba...@nic.cl
Administrador de DNS, NIC Chile