domain name system – How to test DNS glue record? – Server Fault
Posted by jpluimers on 2016/05/26
Thanks Adrian W for providing the below example in your answer about obtaining GLUE record information for a domain.
It is an excellent showcase for the $IFS Internal Field Separator available in any nx shell.
In this case it is used to get the TLD (top-level domain) from the domain name specified at the command-line.
After that, it obtains the name servers for that TLD, and queries the glue records there, both using dig.
Here is a little shell script which implements Alnitak’s answer:
#!/bin/sh S=${IFS} IFS=. for P in $1; do TLD=${P} done IFS=${S} echo "TLD: ${TLD}" DNSLIST=$(dig +short ${TLD}. NS) for DNS in ${DNSLIST}; do echo "Checking ${DNS}" dig +norec +nocomments +noquestion +nostats +nocmd @${DNS} $1 NS done
Pass the name of the domain as parameter:
./checkgluerecords.sh example.org
–jeroen
via domain name system – How to test DNS glue record? – Server Fault.
Leave a Reply