I'd like to use a command-line tool to list a (primary) zone's configured secondary servers, if any.
Dnscmd comes close with:
dnscmd server /ZoneResetSecondaries:[list of secondaries]
But, I don't want to clobber any current settings, I just want to review them. PowerShell (even on Server 2012) doesn't seem to help.
Thanks.
Best Answer
You are most correct in that you can:
I've previously written about parsing
dnscmd
output using PowerShell, and this should accomplish step 1:Now you can list all Primary zones with:
You could then use the Zone array to automate the lookup for all the primary zones: