Link to home
Start Free TrialLog in
Avatar of aaeandcee
aaeandcee

asked on

Compare DNS Zone Transfers

Hello-

I am looking for a way to compare AXFRs from two servers.  We have upgraded our VitalQIP Enterprise server and want to make sure no DNS entries were dropped from the central database during the upgrade process.  We want to pull the DNS Zone from the production server and compare entry for entry with that in a test environment.  

Thank you!
Avatar of mikebernhardt
mikebernhardt
Flag of United States of America image

Just put both db files on the same machine with ftp or something, and use diff to compare. If you're on Windows, there's freeware called CSDiff that does the same thing (compares 2 files and shows you what's different. Or write a little perl script that will parse the file, pull only lines that start with an IP address, sort them and count them. If the count is different, it should be easy to find the missing entries if they're sorted.
Avatar of aaeandcee
aaeandcee

ASKER

I'm dealing with zones that are several thousand entries in all.  We have tried WinDiff in the past, but with WinDiff we have missed entries.  We are looking for something that would definitively compare zone files, not just line placement, count, etc.
I don't think you'll find a tool that's made to do the somewhat uncommon job you have in mind, and why pay more? I would definitely write a perl script to do it then. I mean, it's a text file. Let it parse for only the actual host entries, then sort and count them (that way you don't get caught because of an extra line with a semicolon in it or something). If the count is the same, you're good. If not, THEN use diff and you'll find the exact spot where the mismatch occurs.
That doesn't sound like too bad of an idea.  I'm not that proficient with Perl, any examples on how to write the script?
ASKER CERTIFIED SOLUTION
Avatar of mikebernhardt
mikebernhardt
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial