-   Linux - Networking (
-   -   dns: request all host records? (

stateless 01-07-2014 05:20 PM

dns: request all host records?
Can dig (or some other tool) ask a dns server to give you all A/AAAA records for a zone? Seems like that would be rather handy, but somehow missing it in the manual pages...

catkin 01-08-2014 03:06 AM


dig @server_ID <name of zone file>
In case a TSIG is required, use -k <path of file containing the TSIG key>

IDK about other validating mechanisms apart from TSIG.

EIDT: that gives the entire zone file; you could post-process the output to get only the record types you want.

rhoekstra 01-08-2014 03:25 AM


dig @host zone
does only answer the host entries for the specified zone. (in my case, the zone file equales the zone name, so I can't vouch for situation where that would be different.


dig axfr @host zone
would do a zone transfer though if settings allow (!!), so you can parse indeed as catkin mentions. you'd have to grep for A and AAAA fields.

All times are GMT -5. The time now is 01:11 PM.