(Spelled by the program itself as "DiG", but I have no idea where this sudden burst of l33tness has come...)

Short for domain information groper (though this smells like a backronym).

It's a command-line tool used to fetch information from DNS servers. It can query all sorts of stuff from the DNS servers with various criteria.

For example, it's useful for finding out for whom some specific IP address belongs to:

holt:~$ dig -x

; <<>> DiG 8.2 <<>> -x 
;; res options: init recurs defnam dnsrch
;; got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 4
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 2
;;, type = ANY, class = IN

;; ANSWER SECTION:  23h58m42s IN PTR  everything2.com.

14.170.206.in-addr.arpa.  23h58m42s IN NS  ns1.upn.net.
14.170.206.in-addr.arpa.  23h58m42s IN NS  ns2.upn.net.

ns1.upn.net.		18h34m51s IN A
ns2.upn.net.		18h34m51s IN A

;; Total query time: 34 msec
;; FROM: holt to SERVER: default --
;; WHEN: Tue Sep 18 15:42:14 2001
;; MSG SIZE  sent: 45  rcvd: 172

Of course, it's not exactly human-readable - for most needs, you probably want to use

  • The host(1) program - this will return the DNS name based on IP, and IP based on DNS.
  • Use whois(1) to find out who owns the IP block (ARIN's whois server knows.)