named-checkzone.html revision 3a5fe5abf08f16b8d31ab8ee9a788063110ef000
0dc2366f7b9f9f36e10909b1e95edbf2a261c2acVenugopal Iyer - Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC")
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - Copyright (C) 2000-2002 Internet Software Consortium.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - Permission to use, copy, modify, and/or distribute this software for any
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - purpose with or without fee is hereby granted, provided that the above
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - copyright notice and this permission notice appear in all copies.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang - PERFORMANCE OF THIS SOFTWARE.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<!-- $Id: named-checkzone.html,v 1.45 2009/11/11 01:14:41 tbox Exp $ -->
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<meta name="generator" content="DocBook XSL Stylesheets V1.71.1">
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<a name="man.named-checkzone"></a><div class="titlepage"></div>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<p><span class="application">named-checkzone</span>, <span class="application">named-compilezone</span> — zone file validity checking or converting tool</p>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<div class="cmdsynopsis"><p><code class="command">named-checkzone</code> [<code class="option">-d</code>] [<code class="option">-h</code>] [<code class="option">-j</code>] [<code class="option">-q</code>] [<code class="option">-v</code>] [<code class="option">-c <em class="replaceable"><code>class</code></em></code>] [<code class="option">-f <em class="replaceable"><code>format</code></em></code>] [<code class="option">-F <em class="replaceable"><code>format</code></em></code>] [<code class="option">-i <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-k <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-m <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-M <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-n <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-s <em class="replaceable"><code>style</code></em></code>] [<code class="option">-S <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-t <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-w <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-D</code>] [<code class="option">-W <em class="replaceable"><code>mode</code></em></code>] {zonename} {filename}</p></div>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<div class="cmdsynopsis"><p><code class="command">named-compilezone</code> [<code class="option">-d</code>] [<code class="option">-j</code>] [<code class="option">-q</code>] [<code class="option">-v</code>] [<code class="option">-c <em class="replaceable"><code>class</code></em></code>] [<code class="option">-C <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-f <em class="replaceable"><code>format</code></em></code>] [<code class="option">-F <em class="replaceable"><code>format</code></em></code>] [<code class="option">-i <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-k <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-m <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-n <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-o <em class="replaceable"><code>filename</code></em></code>] [<code class="option">-s <em class="replaceable"><code>style</code></em></code>] [<code class="option">-t <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-w <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-D</code>] [<code class="option">-W <em class="replaceable"><code>mode</code></em></code>] {<code class="option">-o <em class="replaceable"><code>filename</code></em></code>} {zonename} {filename}</p></div>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<p><span><strong class="command">named-checkzone</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang checks the syntax and integrity of a zone file. It performs the
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang same checks as <span><strong class="command">named</strong></span> does when loading a
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang zone. This makes <span><strong class="command">named-checkzone</strong></span> useful for
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang checking zone files before configuring them into a name server.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">named-compilezone</strong></span> is similar to
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">named-checkzone</strong></span>, but it always dumps the
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang zone contents to a specified file in a specified format.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Additionally, it applies stricter check levels by default,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang since the dump output will be used as an actual zone file
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang loaded by <span><strong class="command">named</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang When manually specified otherwise, the check levels must at
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang least be as strict as those specified in the
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">named</strong></span> configuration file.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Enable debugging.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Print the usage summary and exit.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Quiet mode - exit code only.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Print the version of the <span><strong class="command">named-checkzone</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang program and exit.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang When loading the zone file read the journal if it exists.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-c <em class="replaceable"><code>class</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Specify the class of the zone. If not specified, "IN" is assumed.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-i <em class="replaceable"><code>mode</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Perform post-load zone integrity checks. Possible modes are
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"full"</strong></span> (default),
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"full-sibling"</strong></span>,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"local"</strong></span>,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"local-sibling"</strong></span> and
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"none"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Mode <span><strong class="command">"full"</strong></span> checks that MX records
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang refer to A or AAAA record (both in-zone and out-of-zone
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang hostnames). Mode <span><strong class="command">"local"</strong></span> only
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang checks MX records which refer to in-zone hostnames.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Mode <span><strong class="command">"full"</strong></span> checks that SRV records
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang refer to A or AAAA record (both in-zone and out-of-zone
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang hostnames). Mode <span><strong class="command">"local"</strong></span> only
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang checks SRV records which refer to in-zone hostnames.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Mode <span><strong class="command">"full"</strong></span> checks that delegation NS
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang records refer to A or AAAA record (both in-zone and out-of-zone
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang hostnames). It also checks that glue address records
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang in the zone match those advertised by the child.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Mode <span><strong class="command">"local"</strong></span> only checks NS records which
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang refer to in-zone hostnames or that some required glue exists,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang that is when the nameserver is in a child zone.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Mode <span><strong class="command">"full-sibling"</strong></span> and
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"local-sibling"</strong></span> disable sibling glue
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang checks but are otherwise the same as <span><strong class="command">"full"</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang and <span><strong class="command">"local"</strong></span> respectively.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Mode <span><strong class="command">"none"</strong></span> disables the checks.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-f <em class="replaceable"><code>format</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Specify the format of the zone file.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Possible formats are <span><strong class="command">"text"</strong></span> (default)
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang and <span><strong class="command">"raw"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-F <em class="replaceable"><code>format</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Specify the format of the output file specified.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Possible formats are <span><strong class="command">"text"</strong></span> (default)
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang and <span><strong class="command">"raw"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang For <span><strong class="command">named-checkzone</strong></span>,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang this does not cause any effects unless it dumps the zone
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-k <em class="replaceable"><code>mode</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Perform <span><strong class="command">"check-names"</strong></span> checks with the
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang specified failure mode.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Possible modes are <span><strong class="command">"fail"</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang (default for <span><strong class="command">named-compilezone</strong></span>),
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"warn"</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang (default for <span><strong class="command">named-checkzone</strong></span>) and
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"ignore"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-m <em class="replaceable"><code>mode</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Specify whether MX records should be checked to see if they
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang are addresses. Possible modes are <span><strong class="command">"fail"</strong></span>,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"warn"</strong></span> (default) and
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"ignore"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-M <em class="replaceable"><code>mode</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Check if a MX record refers to a CNAME.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Possible modes are <span><strong class="command">"fail"</strong></span>,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"warn"</strong></span> (default) and
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"ignore"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-n <em class="replaceable"><code>mode</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Specify whether NS records should be checked to see if they
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang are addresses.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Possible modes are <span><strong class="command">"fail"</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang (default for <span><strong class="command">named-compilezone</strong></span>),
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"warn"</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang (default for <span><strong class="command">named-checkzone</strong></span>) and
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"ignore"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-o <em class="replaceable"><code>filename</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Write zone output to <code class="filename">filename</code>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang If <code class="filename">filename</code> is <code class="filename">-</code> then
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang write to standard out.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang This is mandatory for <span><strong class="command">named-compilezone</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-s <em class="replaceable"><code>style</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Specify the style of the dumped zone file.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Possible styles are <span><strong class="command">"full"</strong></span> (default)
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang and <span><strong class="command">"relative"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang The full format is most suitable for processing
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang automatically by a separate script.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang On the other hand, the relative format is more
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang human-readable and is thus suitable for editing by hand.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang For <span><strong class="command">named-checkzone</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang this does not cause any effects unless it dumps the zone
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang It also does not have any meaning if the output format
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang is not text.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-S <em class="replaceable"><code>mode</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Check if a SRV record refers to a CNAME.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Possible modes are <span><strong class="command">"fail"</strong></span>,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"warn"</strong></span> (default) and
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"ignore"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-t <em class="replaceable"><code>directory</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Chroot to <code class="filename">directory</code> so that
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang directives in the configuration file are processed as if
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang run by a similarly chrooted named.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-w <em class="replaceable"><code>directory</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang chdir to <code class="filename">directory</code> so that
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang filenames in master file $INCLUDE directives work. This
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang is similar to the directory clause in
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Dump zone file in canonical format.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang This is always enabled for <span><strong class="command">named-compilezone</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<dt><span class="term">-W <em class="replaceable"><code>mode</code></em></span></dt>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Specify whether to check for non-terminal wildcards.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Non-terminal wildcards are almost always the result of a
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang failure to understand the wildcard matching algorithm (RFC 1034).
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang Possible modes are <span><strong class="command">"warn"</strong></span> (default)
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span><strong class="command">"ignore"</strong></span>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang The domain name of the zone being checked.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang The name of the zone file.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<p><span><strong class="command">named-checkzone</strong></span>
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang returns an exit status of 1 if
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang errors were detected and 0 otherwise.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<p><span class="citerefentry"><span class="refentrytitle">named</span>(8)</span>,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <span class="citerefentry"><span class="refentrytitle">named-checkconf</span>(8)</span>,
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang <em class="citetitle">BIND 9 Administrator Reference Manual</em>.
22a84b8d79248a611e4ba663a268d3c4bed054acQuaker Fang<p><span class="corpauthor">Internet Systems Consortium</span>