Bv9ARM.ch03.html revision d6fa26d0adaec6c910115be34fe7a5a5f402c14f
d6fa26d0adaec6c910115be34fe7a5a5f402c14fMark Andrews<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
71cef386fae61275b03e203825680b39fedaa8c6Tinderbox User - Copyright (C) 2000-2015 Internet Systems Consortium, Inc. ("ISC")
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User - This Source Code Form is subject to the terms of the Mozilla Public
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User - License, v. 2.0. If a copy of the MPL was not distributed with this
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User - file, You can obtain one at http://mozilla.org/MPL/2.0/.
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<title>Chapter�3.�Name Server Configuration</title>
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt<link rel="home" href="Bv9ARM.html" title="BIND 9 Administrator Reference Manual">
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<link rel="up" href="Bv9ARM.html" title="BIND 9 Administrator Reference Manual">
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<link rel="prev" href="Bv9ARM.ch02.html" title="Chapter�2.�BIND Resource Requirements">
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<link rel="next" href="Bv9ARM.ch04.html" title="Chapter�4.�Advanced DNS Features">
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<tr><th colspan="3" align="center">Chapter�3.�Name Server Configuration</th></tr>
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<a accesskey="p" href="Bv9ARM.ch02.html">Prev</a>�</td>
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<td width="20%" align="right">�<a accesskey="n" href="Bv9ARM.ch04.html">Next</a>
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<div class="titlepage"><div><div><h1 class="title">
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<a name="Bv9ARM.ch03"></a>Chapter�3.�Name Server Configuration</h1></div></div></div>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<dt><span class="section"><a href="Bv9ARM.ch03.html#sample_configuration">Sample Configurations</a></span></dt>
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<dt><span class="section"><a href="Bv9ARM.ch03.html#cache_only_sample">A Caching-only Name Server</a></span></dt>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<dt><span class="section"><a href="Bv9ARM.ch03.html#auth_only_sample">An Authoritative-only Name Server</a></span></dt>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<dt><span class="section"><a href="Bv9ARM.ch03.html#load_balancing">Load Balancing</a></span></dt>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<dt><span class="section"><a href="Bv9ARM.ch03.html#ns_operations">Name Server Operations</a></span></dt>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<dt><span class="section"><a href="Bv9ARM.ch03.html#tools">Tools for Use With the Name Server Daemon</a></span></dt>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<dt><span class="section"><a href="Bv9ARM.ch03.html#signals">Signals</a></span></dt>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User In this chapter we provide some suggested configurations along
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User with guidelines for their use. We suggest reasonable values for
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User certain option settings.
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<div class="titlepage"><div><div><h2 class="title" style="clear: both">
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<a name="sample_configuration"></a>Sample Configurations</h2></div></div></div>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<div class="titlepage"><div><div><h3 class="title">
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User<a name="cache_only_sample"></a>A Caching-only Name Server</h3></div></div></div>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User The following sample configuration is appropriate for a caching-only
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt name server for use by clients internal to a corporation. All
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt from outside clients are refused using the <span class="command"><strong>allow-query</strong></span>
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt option. Alternatively, the same effect could be achieved using
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt firewall rules.
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User// Two corporate subnets we wish to allow queries from.
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox Useracl corpnets { 192.168.4.0/24; 192.168.7.0/24; };
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User // Working directory
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt allow-query { corpnets; };
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User// Provide a reverse mapping for the loopback
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt// address 127.0.0.1
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<div class="titlepage"><div><div><h3 class="title">
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User<a name="auth_only_sample"></a>An Authoritative-only Name Server</h3></div></div></div>
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User This sample configuration is for an authoritative-only server
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User that is the master server for "<code class="filename">example.com</code>"
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt and a slave for the subdomain "<code class="filename">eng.example.com</code>".
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt // Working directory
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User // Do not allow access to cache
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User allow-query-cache { none; };
7e71f05d8643aca84914437c900cb716444507e4Tinderbox User // This is the default
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User allow-query { any; };
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User // Do not provide recursive service
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User recursion no;
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User// Provide a reverse mapping for the loopback
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User// address 127.0.0.1
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt type master;
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt// We are the master server for example.com
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt type master;
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt // IP addresses of slave servers allowed to
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt allow-transfer {
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt 192.168.4.14;
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt 192.168.5.53;
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt// We are a slave server for eng.example.com
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt // IP address of eng.example.com master server
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt masters { 192.168.4.12; };
b66b333f59cf51ef87f973084a5023acd9317fb2Evan Hunt<div class="titlepage"><div><div><h2 class="title" style="clear: both">
The <span class="command"><strong>dig</strong></span>, <span class="command"><strong>host</strong></span>, and
<dt><span class="term"><a name="dig"></a><span class="command"><strong>dig</strong></span></span></dt>
<div class="cmdsynopsis"><p><code class="command">dig</code> [@<em class="replaceable"><code>server</code></em>] <em class="replaceable"><code>domain</code></em> [<em class="replaceable"><code>query-type</code></em>] [<em class="replaceable"><code>query-class</code></em>] [+<em class="replaceable"><code>query-option</code></em>] [-<em class="replaceable"><code>dig-option</code></em>] [%<em class="replaceable"><code>comment</code></em>]</p></div>
<div class="cmdsynopsis"><p><code class="command">host</code> [-aCdlnrsTwv] [-c <em class="replaceable"><code>class</code></em>] [-N <em class="replaceable"><code>ndots</code></em>] [-t <em class="replaceable"><code>type</code></em>] [-W <em class="replaceable"><code>timeout</code></em>] [-R <em class="replaceable"><code>retries</code></em>] [-m <em class="replaceable"><code>flag</code></em>] [-4] [-6] <em class="replaceable"><code>hostname</code></em> [<em class="replaceable"><code>server</code></em>]</p></div>
<div class="cmdsynopsis"><p><code class="command">nslookup</code> [-option...] [[<em class="replaceable"><code>host-to-find</code></em>] | [- [server]]]</p></div>
<a name="named-checkconf"></a><span class="term"><span class="command"><strong>named-checkconf</strong></span></span>
<div class="cmdsynopsis"><p><code class="command">named-checkconf</code> [-jvz] [-t <em class="replaceable"><code>directory</code></em>] [<em class="replaceable"><code>filename</code></em>]</p></div>
<a name="named-checkzone"></a><span class="term"><span class="command"><strong>named-checkzone</strong></span></span>
<div class="cmdsynopsis"><p><code class="command">named-checkzone</code> [-djqvD] [-c <em class="replaceable"><code>class</code></em>] [-o <em class="replaceable"><code>output</code></em>] [-t <em class="replaceable"><code>directory</code></em>] [-w <em class="replaceable"><code>directory</code></em>] [-k <em class="replaceable"><code>(ignore|warn|fail)</code></em>] [-n <em class="replaceable"><code>(ignore|warn|fail)</code></em>] [-W <em class="replaceable"><code>(ignore|warn)</code></em>] <em class="replaceable"><code>zone</code></em> [<em class="replaceable"><code>filename</code></em>]</p></div>
<a name="named-compilezone"></a><span class="term"><span class="command"><strong>named-compilezone</strong></span></span>
Since <acronym class="acronym">BIND</acronym> 9.2, <span class="command"><strong>rndc</strong></span>
<div class="cmdsynopsis"><p><code class="command">rndc</code> [-c <em class="replaceable"><code>config</code></em>] [-s <em class="replaceable"><code>server</code></em>] [-p <em class="replaceable"><code>port</code></em>] [-y <em class="replaceable"><code>key</code></em>] <em class="replaceable"><code>command</code></em> [<em class="replaceable"><code>command</code></em>...]</p></div>
<p>See <a class="xref" href="man.rndc.html" title="rndc"><span class="refentrytitle"><span class="application">rndc</span></span>(8)</a> for details of
<a class="xref" href="Bv9ARM.ch06.html#controls_statement_definition_and_usage" title="controls Statement Definition and Usage">the section called “<span class="command"><strong>controls</strong></span> Statement Definition and
<span class="command"><strong>key</strong></span>, <span class="command"><strong>server</strong></span> and
<span class="command"><strong>default-server</strong></span>, <span class="command"><strong>default-key</strong></span>,
the name of a key as its argument, as defined by a <span class="command"><strong>key</strong></span> statement.
<span class="command"><strong>key</strong></span> statement in <code class="filename">named.conf</code>.
<span class="command"><strong>algorithm</strong></span> and <span class="command"><strong>secret</strong></span>.
has two clauses: <span class="command"><strong>key</strong></span> and <span class="command"><strong>port</strong></span>.