Domain Information Groper
Encyclopedia
Domain Information Groper (dig) is a network administration command-line tool for querying Domain Name System
Domain name system
The Domain Name System is a hierarchical distributed naming system for computers, services, or any resource connected to the Internet or a private network. It associates various information with domain names assigned to each of the participating entities...

 (DNS) name server
Name server
In computing, a name server is a program or computer server that implements a name-service protocol. It maps a human-recognizable identifier to a system-internal, often numeric, identification or addressing component....

s for any desired DNS records.

Dig is useful for network troubleshooting and for educational purposes. Dig can operate in interactive command line mode or in batch mode by reading requests from an operating system file. When a specific name server is not specified in the command invocation, it will use the operating systems default resolver, usually configured via the resolv.conf
Resolv.conf
resolv.conf is the name of a computer file used in various operating systems to configure the Domain Name System resolver library. The file is a plain-text file usually created by the network administrator or by applications that manage the configuration tasks of the system...

 file. Without any arguments it queries the DNS root zone
DNS root zone
A DNS root zone is the top-level DNS zone in a Domain Name System hierarchy. Most commonly it refers to the root zone of the largest global DNS, deployed for the Internet. Ultimate authority over the DNS root zone rests with the US Department of Commerce NTIA...

.

Dig supports Internationalized Domain Name
Internationalized domain name
An internationalized domain name is an Internet domain name that contains at least one label that is displayed in software applications, in whole or in part, in a language-specific script or alphabet, such as Arabic, Chinese, Russian, Hindi or the Latin alphabet-based characters with diacritics,...

 (IDN) queries.

Dig is part of the BIND
BIND
BIND , or named , is the most widely used DNS software on the Internet.On Unix-like operating systems it is the de facto standard.Originally written by four graduate students at the Computer Systems Research Group at the University of California, Berkeley , the name originates as an acronym from...

 domain name server software suite. Dig replaces older tools such as nslookup
Nslookup
nslookup is a network administration command-line tool available for many computer operating systems for querying the Domain Name System to obtain domain name or IP address mapping or for any other specific DNS record.-Background:...

 and the host
Host (Unix)
host is a simple utility for performing Domain Name System lookups. It was developed by the Internet Systems Consortium , and is released under the ISC license, a permissive free software license....

 program.

Example usage

In this example, dig is used to query for any type of record information in the domain example.com:
  • Command line:


dig any example.com
  • Output:


<<>> DiG 9.6.1 <<>> any example.com
global options
+cm
Got answer
->>HEADER<<- opcode
QUERY, status: NOERROR, id: 401
flags
qr rd ra; QUERY: 1, ANSWER: 4, AUTHORITY: 0, ADDITIONAL:

QUESTION SECTION

example.com. IN ANY
ANSWER SECTION

example.com. 172719 IN NS a.iana-servers.net.
example.com. 172719 IN NS b.iana-servers.net.
example.com. 172719 IN A 208.77.188.166
example.com. 172719 IN SOA dns1.icann.org. hostmaster.icann.org. 2007051703 7200 3600 1209600 86400
Query time
1 mse
SERVER
::1#53(::1
WHEN
Wed Aug 12 11:40:43 200
MSG SIZE rcvd
15



Queries may be directed to designated DNS servers for specific records; in this example, MX record
MX record
A mail exchanger record is a type of resource record in the Domain Name System that specifies a mail server responsible for accepting email messages on behalf of a recipient's domain, and a preference value used to prioritize mail delivery if multiple mail servers are available...

s:
  • Command:


dig MX wikimedia.org @ns0.wikimedia.org
  • Output:


<<>> DiG 9.6.1 <<>> MX wikimedia.org @ns0.wikimedia.org
global options
+cm
Got answer
->>HEADER<<- opcode
QUERY, status: NOERROR, id: 6114
flags
qr aa rd; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL:
WARNING
recursion requested but not availabl

QUESTION SECTION

wikimedia.org. IN MX
ANSWER SECTION

wikimedia.org. 3600 IN MX 10 mchenry.wikimedia.org.
wikimedia.org. 3600 IN MX 50 lists.wikimedia.org.
ADDITIONAL SECTION

mchenry.wikimedia.org. 3600 IN A 208.80.152.186
lists.wikimedia.org. 3600 IN A 91.198.174.5
Query time
73 mse
SERVER
208.80.152.130#53(208.80.152.130
WHEN
Wed Aug 12 11:51:03 200
MSG SIZE rcvd
10


See also

  • List of DNS record types
  • nslookup
    Nslookup
    nslookup is a network administration command-line tool available for many computer operating systems for querying the Domain Name System to obtain domain name or IP address mapping or for any other specific DNS record.-Background:...

    , a similar tool
  • whois
    WHOIS
    WHOIS is a query and response protocol that is widely used for querying databases that store the registered users or assignees of an Internet resource, such as a domain name, an IP address block, or an autonomous system, but is also used for a wider range of other information. The protocol stores...

  • host (Unix)
    Host (Unix)
    host is a simple utility for performing Domain Name System lookups. It was developed by the Internet Systems Consortium , and is released under the ISC license, a permissive free software license....

    , a simple utility for performing Domain Name System lookups

External links

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK