dig

Domain Information Groper

dig $DOMAIN

#To just get the ip address

  • dig $DOMAIN +nocomments +noauthority +noadditional +nostats
  • dig $DOMAIN +noall +answer
  • dig $DOMAIN +short

#To use a specific query type

  • dig -t $TYPE $DOMAIN $OPTIONS

#To view ALL DNS record types use query ANY

  • dig -t ANY $DOMAIN $OPTIONS
  • dig $DOMAIN ANY $OPTIONS

#To do a DNS reverse look up

  • dig -x $IPV4 +short

#To use a specific DNS server

  • dig @$DNSSERVER $DOMAIN

Leave a Reply