mdig.html revision ee2e5fec653c2ccbe1531d6e0bded2218d6a76af
5cd4555ad444fd391002ae32450572054369fd42Rob Austein - Copyright (C) 2015, 2016 Internet Systems Consortium, Inc. ("ISC")
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington - Permission to use, copy, modify, and/or distribute this software for any
c1a883f2e04d94e99c433b1f6cfd0c0338f4ed85Mark Andrews - purpose with or without fee is hereby granted, provided that the above
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews - copyright notice and this permission notice appear in all copies.
ec5347e2c775f027573ce5648b910361aa926c01Automatic Updater - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington - AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews - PERFORMANCE OF THIS SOFTWARE.
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
f5d30e2864e048a42c4dc1134993ae7efdb5d6c3Mark Andrews<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
b5ad6dfea4cc3e7d1d322ac99f1e5a31096837c4Mark Andrews<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry">
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<a name="man.mdig"></a><div class="titlepage"></div>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<p><span class="application">mdig</span> — DNS pipelined lookup utility</p>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<div class="cmdsynopsis"><p><code class="command">mdig</code> {@server} [<code class="option">-f <em class="replaceable"><code>filename</code></em></code>] [<code class="option">-h</code>] [<code class="option">-v</code>] [<code class="option">-4</code>] [<code class="option">-6</code>] [<code class="option">-b <em class="replaceable"><code>address</code></em></code>] [<code class="option">-p <em class="replaceable"><code>port#</code></em></code>] [<code class="option">-c <em class="replaceable"><code>class</code></em></code>] [<code class="option">-t <em class="replaceable"><code>type</code></em></code>] [<code class="option">-i</code>] [<code class="option">-x <em class="replaceable"><code>addr</code></em></code>] [plusopt...]</p></div>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<div class="cmdsynopsis"><p><code class="command">mdig</code> {-h}</p></div>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<div class="cmdsynopsis"><p><code class="command">mdig</code> [@server] {global-opt...} {
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley {local-opt...}
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein<p><span class="command"><strong>mdig</strong></span>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein is a multiple/pipelined query version of <span class="command"><strong>dig</strong></span>:
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein instead of waiting for a response after sending each query,
c1a883f2e04d94e99c433b1f6cfd0c0338f4ed85Mark Andrews it begins by sending all queries. Responses are displayed in
4eb998928b9aef0ceda42d7529980d658138698aEvan Hunt the order in which they are received, not in the order the
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein corresponding queries were sent.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein <span class="command"><strong>mdig</strong></span> options are a subset of the
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein <span class="command"><strong>dig</strong></span> options, and are divided into "anywhere
f5d30e2864e048a42c4dc1134993ae7efdb5d6c3Mark Andrews options" which can occur anywhere, "global options" which must
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein occur before the query name (or they are ignored with a warning),
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein and "local options" which apply to the next query on the command
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley The {@server} option is a mandatory global
c4f9e613e12f03795bee18cf2ca8e6a9d39d6468Mark Andrews option. It is the name or IP address of the name server to query.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley (Unlike <span class="command"><strong>dig</strong></span>, this value is not retrieved from
a769eca4e3b223866b01dc8f7a4dde8d9e49bab0Mark Andrews <code class="filename">/etc/resolv.conf</code>.) It can be an IPv4 address
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley in dotted-decimal notation, an IPv6 address in colon-delimited
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley notation, or a hostname. When the supplied
b435b1ded3def3159f597953d21dffc1615cb250Brian Wellington <em class="parameter"><code>server</code></em> argument is a hostname,
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley <span class="command"><strong>mdig</strong></span> resolves that name before querying
9b6a170d22d61026d31bde87523f3320628b6ebcBrian Wellington the name server.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<p><span class="command"><strong>mdig</strong></span>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley provides a number of query options which affect
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley the way in which lookups are made and the results displayed. Some of
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley these set or reset flag bits in the query header, some determine which
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein sections of the answer get printed, and others determine the timeout
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein and retry strategies.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Each query option is identified by a keyword preceded by a plus
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein sign (<code class="literal">+</code>). Some keywords set or reset an
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein option. These may be preceded by the string <code class="literal">no</code>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein to negate the meaning of that keyword. Other keywords assign
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley values to options like the timeout interval. They have the
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein form <code class="option">+keyword=value</code>.
4eb998928b9aef0ceda42d7529980d658138698aEvan Hunt The <code class="option">-f</code> option makes <span class="command"><strong>mdig</strong></span>
4eb998928b9aef0ceda42d7529980d658138698aEvan Hunt operate in batch mode by reading a list of lookup requests to
4eb998928b9aef0ceda42d7529980d658138698aEvan Hunt process from the file <em class="parameter"><code>filename</code></em>. The file
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein contains a number of queries, one per line. Each entry in the
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein file should be organized in the same way they would be presented
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein as queries to <span class="command"><strong>mdig</strong></span> using the command-line interface.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein The <code class="option">-h</code> causes <span class="command"><strong>mdig</strong></span> to
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein print the detailed help with the full list of options and exit.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley The <code class="option">-v</code> causes <span class="command"><strong>mdig</strong></span> to
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley print the version number and exit.
c4f9e613e12f03795bee18cf2ca8e6a9d39d6468Mark Andrews The <code class="option">-4</code> option forces <span class="command"><strong>mdig</strong></span> to
c4f9e613e12f03795bee18cf2ca8e6a9d39d6468Mark Andrews only use IPv4 query transport.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein The <code class="option">-6</code> option forces <span class="command"><strong>mdig</strong></span> to
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein only use IPv6 query transport.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein The <code class="option">-b</code> option sets the source IP address of the
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein query to <em class="parameter"><code>address</code></em>. This must be a valid
c4f9e613e12f03795bee18cf2ca8e6a9d39d6468Mark Andrews address on one of the host's network interfaces or "0.0.0.0" or
c4f9e613e12f03795bee18cf2ca8e6a9d39d6468Mark Andrews "::". An optional port may be specified by appending
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley "#<port>"
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein The <code class="option">-p</code> option is used when a non-standard port
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein number is to be queried.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein <em class="parameter"><code>port#</code></em> is the port number
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein that <span class="command"><strong>mdig</strong></span> will send its queries instead of
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein the standard DNS port number 53. This option would be used to
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein test a name server that has been configured to listen for
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley queries on a non-standard port number.
a769eca4e3b223866b01dc8f7a4dde8d9e49bab0Mark Andrews The global query options are:
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein<div class="variablelist"><dl class="variablelist">
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein<dt><span class="term"><code class="option">+[no]additional</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Display [do not display] the additional section of a
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein reply. The default is to display it.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein<dt><span class="term"><code class="option">+[no]all</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Set or clear all display flags.
a769eca4e3b223866b01dc8f7a4dde8d9e49bab0Mark Andrews<dt><span class="term"><code class="option">+[no]answer</code></span></dt>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley Display [do not display] the answer section of a
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley reply. The default is to display it.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein<dt><span class="term"><code class="option">+[no]authority</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Display [do not display] the authority section of a
6043e41fcf5dc91aa8a981c966512d73bdec31c1Mark Andrews reply. The default is to display it.
6043e41fcf5dc91aa8a981c966512d73bdec31c1Mark Andrews<dt><span class="term"><code class="option">+[no]besteffort</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Attempt to display the contents of messages which are
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein malformed. The default is to not display malformed
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+[no]cl</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Display [do not display] the CLASS when printing the
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein<dt><span class="term"><code class="option">+[no]comments</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Toggle the display of comment lines in the output.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein The default is to print comments.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+[no]crypto</code></span></dt>
b435b1ded3def3159f597953d21dffc1615cb250Brian Wellington Toggle the display of cryptographic fields in DNSSEC
b435b1ded3def3159f597953d21dffc1615cb250Brian Wellington records. The contents of these field are unnecessary
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein to debug most DNSSEC validation failures and removing
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein them makes it easier to see the common failures. The
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein default is to display the fields. When omitted they
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein are replaced by the string "[omitted]" or in the
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein DNSKEY case the key id is displayed as the replacement,
b435b1ded3def3159f597953d21dffc1615cb250Brian Wellington e.g. "[ key id = value ]".
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+dscp[=value]</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Set the DSCP code point to be used when sending the
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein query. Valid DSCP code points are in the range
122c58bd11790c7576cdb1c6fd8e4439d0d7f7a5Mark Andrews [0..63]. By default no code point is explicitly set.
122c58bd11790c7576cdb1c6fd8e4439d0d7f7a5Mark Andrews<dt><span class="term"><code class="option">+[no]multiline</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Print records like the SOA records in a verbose
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein multi-line format with human-readable comments. The
122c58bd11790c7576cdb1c6fd8e4439d0d7f7a5Mark Andrews default is to print each record on a single line, to
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein facilitate machine parsing of the <span class="command"><strong>mdig</strong></span>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein<dt><span class="term"><code class="option">+[no]question</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Print [do not print] the question section of a query
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein when an answer is returned. The default is to print
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein the question section as a comment.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein<dt><span class="term"><code class="option">+[no]rrcomments</code></span></dt>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley Toggle the display of per-record comments in the
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley output (for example, human-readable key information
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley about DNSKEY records). The default is not to print
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley record comments unless multiline mode is active.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+[no]short</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Provide a terse answer. The default is to print the
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley answer in a verbose form.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+split=W</code></span></dt>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley Split long hex- or base64-formatted fields in resource
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley records into chunks of <em class="parameter"><code>W</code></em>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein characters (where <em class="parameter"><code>W</code></em> is rounded
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein up to the nearest multiple of 4).
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein <em class="parameter"><code>+nosplit</code></em> or
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley <em class="parameter"><code>+split=0</code></em> causes fields not to
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley be split at all. The default is 56 characters, or
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein 44 characters when multiline mode is active.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+[no]tcp</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Use [do not use] TCP when querying name servers. The
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley default behavior is to use UDP.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+[no]ttlid</code></span></dt>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley Display [do not display] the TTL when printing the
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+[no]ttlunits</code></span></dt>
b39ee56af9c9a690db068a98cf44af175dbb45edMark Andrews Display [do not display] the TTL in friendly human-readable
b39ee56af9c9a690db068a98cf44af175dbb45edMark Andrews time units of "s", "m", "h", "d", and "w", representing
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley seconds, minutes, hours, days and weeks. Implies +ttlid.
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley<dt><span class="term"><code class="option">+[no]vc</code></span></dt>
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein Use [do not use] TCP when querying name servers. This
561a29af8c54a216e7d30b5b4f6e0d21661654ecMark Andrews alternate syntax to <em class="parameter"><code>+[no]tcp</code></em>
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley is provided for backwards compatibility. The "vc"
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein stands for "virtual circuit".
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley The <code class="option">-c</code> option sets the query class to
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley <em class="parameter"><code>class</code></em>. It can be any valid query class
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein which is supported in BIND 9. The default query class is "IN".
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley The <code class="option">-t</code> option sets the query type to
4610465ed9408cbe434dbfb8be8ea53f48969c91Bob Halley <em class="parameter"><code>type</code></em>. It can be any valid query type
IPv6 addresses to IP6.INT.
under the IP6.ARPA domain. To use the older RFC1886 method
<dt><span class="term"><code class="option">+[no]cookie[<span class="optional">=####</span>]</code></span></dt>
accepted. Setting a named flag (e.g. DO) will silently be