Open System Services Shell and Utilities Reference Manual (G06.27+, H06.04+)
dig(8) OSS Shell and Utilities Reference Manual
/etc/resolv.conf and queries the name servers listed there. The reply from the
name server that responds is displayed.
name is the name of the resource record that is to be looked up.
type indicates what type of query is required: ANY, A, MX, SIG, and so forth. type
can be any valid query type. If no type argument is supplied, dig performs a
lookup for an A record.
Multiple Queries
The BIND 9 implementation of dig supports specifying multiple queries on the command line (in
addition to supporting the -f batch file option). Each of those queries can be supplied with its
own set of flags, options, and query options. In this case, each query argument represents an
individual query in the command-line syntax described above. Each consists of any of the stan-
dard options and flags, the name to be looked up, an optional query type and class, and any query
options that should be applied to that query.
You can also supply a global set of query options, which should be applied to all queries. These
global query options must precede the first set of name, class, type, options, flags, and query
options supplied on the command line. Any global query options (except the +[no]cmd option)
can be overridden by a query-specific set of query options.
EXAMPLES
The following example of a multiple query shows how dig can be used from the command line to
make three lookups:
• An ANY query for www.isc.org
• A reverse lookup of 127.0.0.1
• A query for the NS records of isc.org
dig +qr www.isc.org any -x 127.0.0.1 isc.org ns +noqr
A global query option of +qr is applied, so that dig shows the initial query it made for each
lookup. The final query has a local query option of +noqr, which means that dig does not print
the initial query when it looks up the NS records for isc.org.
FILES
/etc/named.conf
The default named server configuration file. This file defines the recognized
values for class in its zone and view statements.
/etc/resolv.conf
The default domain name server resolver file.
$HOME/.digrc
The local file to override default values for dig use. This file can contain com-
mand line flags and query options, with one flag or query option specification per
line.
RELATED INFORMATION
Commands: dnssec_named(8), named(8), dnssec-keygen(8).
Files: named.conf(4), resolv.conf(5).
Documents: BIND Administrator Reference Manual, RFC1035.
12−12 Hewlett-Packard Company 527188-004