Bv9ARM.ch04.html revision b0e8629055a766d4555a005a283c2889a5974945
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen - Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC")
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen - Copyright (C) 2000-2003 Internet Software Consortium.
d1fff80640050631b06bfab904a34b2ad24601e8Timo Sirainen - Permission to use, copy, modify, and distribute this software for any
47e9fdee55c2074425cf0316f4f64fbbb790301cTimo Sirainen - purpose with or without fee is hereby granted, provided that the above
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen - copyright notice and this permission notice appear in all copies.
38f227941bcf673e0e523c1ac7267bca9cbcd2c4Timo Sirainen - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
38f227941bcf673e0e523c1ac7267bca9cbcd2c4Timo Sirainen - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
47e9fdee55c2074425cf0316f4f64fbbb790301cTimo Sirainen - AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
3e564425db51f3921ce4de11859777135fdedd15Timo Sirainen - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
3e564425db51f3921ce4de11859777135fdedd15Timo Sirainen - PERFORMANCE OF THIS SOFTWARE.
3e564425db51f3921ce4de11859777135fdedd15Timo Sirainen<!-- $Id: Bv9ARM.ch04.html,v 1.74 2007/01/30 00:24:59 marka Exp $ -->
02a6291366caff79793db35d479e2a062bec2af4Timo Sirainen<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
02a6291366caff79793db35d479e2a062bec2af4Timo Sirainen<title>Chapter�4.�Advanced DNS Features</title>
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen<meta name="generator" content="DocBook XSL Stylesheets V1.71.1">
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen<link rel="start" href="Bv9ARM.html" title="BIND 9 Administrator Reference Manual">
8f5b34c22e4c3bfb35ca13c4744867eb5ddbd3d6Timo Sirainen<link rel="up" href="Bv9ARM.html" title="BIND 9 Administrator Reference Manual">
95d9395d15540b3a96f75c7f9fd73e6d8ad5e897Timo Sirainen<link rel="prev" href="Bv9ARM.ch03.html" title="Chapter�3.�Name Server Configuration">
95d9395d15540b3a96f75c7f9fd73e6d8ad5e897Timo Sirainen<link rel="next" href="Bv9ARM.ch05.html" title="Chapter�5.�The BIND 9 Lightweight Resolver">
705f6fbad395e6f014838e797b7dbcaceafd2f1dTimo Sirainen<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
705f6fbad395e6f014838e797b7dbcaceafd2f1dTimo Sirainen<table width="100%" summary="Navigation header">
c5a6a6565be93224fc26522eda855b0990f256e8Timo Sirainen<tr><th colspan="3" align="center">Chapter�4.�Advanced DNS Features</th></tr>
303e375b7e76278f4ec541f49af0476d3e4ee710Timo Sirainen<a accesskey="p" href="Bv9ARM.ch03.html">Prev</a>�</td>
8cca3b43b28365cfee4dc733c00caaeab8ecd2adTimo Sirainen<td width="20%" align="right">�<a accesskey="n" href="Bv9ARM.ch05.html">Next</a>
1358e2c58ce29231485a5cfa454756d429ad3d2cTimo Sirainen<div class="titlepage"><div><div><h2 class="title">
d1fff80640050631b06bfab904a34b2ad24601e8Timo Sirainen<a name="Bv9ARM.ch04"></a>Chapter�4.�Advanced DNS Features</h2></div></div></div>
1959accd3886d99efccd9f98247f21e8fd54da66Timo Sirainen<dt><span class="sect1"><a href="Bv9ARM.ch04.html#notify">Notify</a></span></dt>
1959accd3886d99efccd9f98247f21e8fd54da66Timo Sirainen<dt><span class="sect1"><a href="Bv9ARM.ch04.html#dynamic_update">Dynamic Update</a></span></dt>
a020eb653b2620a989e4795adceb6136037327b2Timo Sirainen<dd><dl><dt><span class="sect2"><a href="Bv9ARM.ch04.html#journal">The journal file</a></span></dt></dl></dd>
a020eb653b2620a989e4795adceb6136037327b2Timo Sirainen<dt><span class="sect1"><a href="Bv9ARM.ch04.html#incremental_zone_transfers">Incremental Zone Transfers (IXFR)</a></span></dt>
a020eb653b2620a989e4795adceb6136037327b2Timo Sirainen<dt><span class="sect1"><a href="Bv9ARM.ch04.html#id2570514">Split DNS</a></span></dt>
a020eb653b2620a989e4795adceb6136037327b2Timo Sirainen<dt><span class="sect1"><a href="Bv9ARM.ch04.html#tsig">TSIG</a></span></dt>
009217abb57a24a4076092e8e4e165545747839eStephan Bosch<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2570965">Generate Shared Keys for Each Pair of Hosts</a></span></dt>
cf0ad1a0bddb0787f3d7b408a96d721a8b2a98a3Timo Sirainen<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2571038">Copying the Shared Secret to Both Machines</a></span></dt>
cf0ad1a0bddb0787f3d7b408a96d721a8b2a98a3Timo Sirainen<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2571049">Informing the Servers of the Key's Existence</a></span></dt>
762e17079d29d9f1838114ff5fec9ceaba8eb6a8Timo Sirainen<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2571089">Instructing the Server to Use the Key</a></span></dt>
b9b841558c5f91db7f5fc71c0ac62aad1bbf6418Timo Sirainen<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2571214">TSIG Key Based Access Control</a></span></dt>
b9b841558c5f91db7f5fc71c0ac62aad1bbf6418Timo Sirainen<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2571259">Errors</a></span></dt>
b9b841558c5f91db7f5fc71c0ac62aad1bbf6418Timo Sirainen<dt><span class="sect1"><a href="Bv9ARM.ch04.html#id2571273">TKEY</a></span></dt>
762e17079d29d9f1838114ff5fec9ceaba8eb6a8Timo Sirainen<dt><span class="sect1"><a href="Bv9ARM.ch04.html#id2571322">SIG(0)</a></span></dt>
0dffa25d211be541ee3c953b23566a1a990789dfTimo Sirainen<dt><span class="sect1"><a href="Bv9ARM.ch04.html#DNSSEC">DNSSEC</a></span></dt>
0dffa25d211be541ee3c953b23566a1a990789dfTimo Sirainen<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2571595">Generating Keys</a></span></dt>
211caf3c233d562b0c8137e5eefae3cb1ef13003Stephan Bosch<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2571665">Signing the Zone</a></span></dt>
211caf3c233d562b0c8137e5eefae3cb1ef13003Stephan Bosch<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2571744">Configuring Servers</a></span></dt>
211caf3c233d562b0c8137e5eefae3cb1ef13003Stephan Bosch<dt><span class="sect1"><a href="Bv9ARM.ch04.html#id2571955">IPv6 Support in <acronym class="acronym">BIND</acronym> 9</a></span></dt>
d1fff80640050631b06bfab904a34b2ad24601e8Timo Sirainen<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2572085">Address Lookups Using AAAA Records</a></span></dt>
38f227941bcf673e0e523c1ac7267bca9cbcd2c4Timo Sirainen<dt><span class="sect2"><a href="Bv9ARM.ch04.html#id2572106">Address to Name Lookups Using Nibble Format</a></span></dt>
a10ed8c47534b4c6b6bf2711ccfe577e720a47b4Timo Sirainen<div class="titlepage"><div><div><h2 class="title" style="clear: both">
fc464e5b2b2ab4d415a5d5b90ce4475d34620a75Timo Sirainen<a name="notify"></a>Notify</h2></div></div></div>
50b9773bebe5c66485728e21e4da6e99db388c92Timo Sirainen <acronym class="acronym">DNS</acronym> NOTIFY is a mechanism that allows master
50b9773bebe5c66485728e21e4da6e99db388c92Timo Sirainen servers to notify their slave servers of changes to a zone's data. In
50b9773bebe5c66485728e21e4da6e99db388c92Timo Sirainen response to a <span><strong class="command">NOTIFY</strong></span> from a master server, the
2fb9ae42f9e36388ec6db24188b9108434043fd0Timo Sirainen slave will check to see that its version of the zone is the
2fb9ae42f9e36388ec6db24188b9108434043fd0Timo Sirainen current version and, if not, initiate a zone transfer.
5d03d9f439e41c90215a3c938ffebe4c2a8ae257Timo Sirainen For more information about <acronym class="acronym">DNS</acronym>
a10ed8c47534b4c6b6bf2711ccfe577e720a47b4Timo Sirainen <span><strong class="command">NOTIFY</strong></span>, see the description of the
97180ea9c26c4de0807daaad21e03c80643b09fdTimo Sirainen <span><strong class="command">notify</strong></span> option in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called “Boolean Options”</a> and
97180ea9c26c4de0807daaad21e03c80643b09fdTimo Sirainen the description of the zone option <span><strong class="command">also-notify</strong></span> in
97180ea9c26c4de0807daaad21e03c80643b09fdTimo Sirainen <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called “Zone Transfers”</a>. The <span><strong class="command">NOTIFY</strong></span>
97180ea9c26c4de0807daaad21e03c80643b09fdTimo Sirainen protocol is specified in RFC 1996.
a10ed8c47534b4c6b6bf2711ccfe577e720a47b4Timo Sirainen<div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
6dc2060d6e0261e4bfd453f1eb1c165cc8d905c1Timo Sirainen As a slave zone can also be a master to other slaves, named,
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen by default, sends <span><strong class="command">NOTIFY</strong></span> messages for every zone
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen it loads. Specifying <span><strong class="command">notify master-only;</strong></span> will
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen cause named to only send <span><strong class="command">NOTIFY</strong></span> for master
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen zones that it loads.
3482fee0e3733456512ba110780824e6daa7ff9fTimo Sirainen<div class="titlepage"><div><div><h2 class="title" style="clear: both">
3b22894b8805b186c73d8b754001e8d7e944be85Timo Sirainen<a name="dynamic_update"></a>Dynamic Update</h2></div></div></div>
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen Dynamic Update is a method for adding, replacing or deleting
61d3fd14828b68d789f3df73d1dbed56e37b7931Timo Sirainen records in a master server by sending it a special form of DNS
61d3fd14828b68d789f3df73d1dbed56e37b7931Timo Sirainen messages. The format and meaning of these messages is specified
2092da86f3a332e8d7eae1300a3b9852fed8f2f8Sergey Kitov in RFC 2136.
2092da86f3a332e8d7eae1300a3b9852fed8f2f8Sergey Kitov Dynamic update is enabled by including an
2092da86f3a332e8d7eae1300a3b9852fed8f2f8Sergey Kitov <span><strong class="command">allow-update</strong></span> or <span><strong class="command">update-policy</strong></span>
2092da86f3a332e8d7eae1300a3b9852fed8f2f8Sergey Kitov clause in the <span><strong class="command">zone</strong></span> statement. The
62fc2fe221eccc834ac6b11b94b55335d5027cd1Timo Sirainen <span><strong class="command">tkey-gssapi-credential</strong></span> and
62fc2fe221eccc834ac6b11b94b55335d5027cd1Timo Sirainen <span><strong class="command">tkey-domain</strong></span> clauses in the
3b22894b8805b186c73d8b754001e8d7e944be85Timo Sirainen <span><strong class="command">options</strong></span> statement enable the
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen server to negotiate keys that can be matched against those
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen in <span><strong class="command">update-policy</strong></span> or
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen <span><strong class="command">allow-update</strong></span>.
d1bf4ae66b8bf3b9e28df1823d6d4adda2b923b6Timo Sirainen Updating of secure zones (zones using DNSSEC) follows
d1bf4ae66b8bf3b9e28df1823d6d4adda2b923b6Timo Sirainen RFC 3007: RRSIG and NSEC records affected by updates are automatically
4dc81fe17cc3aca2e8e9ccb988f90bae12ca2ad0Timo Sirainen regenerated by the server using an online zone key.
4dc81fe17cc3aca2e8e9ccb988f90bae12ca2ad0Timo Sirainen Update authorization is based
a7b9a392af1ee67134ac63435601d6abb819beeeTimo Sirainen on transaction signatures and an explicit server policy.
55e04e5659b27c520633835d3f04e2eca7f21117Timo Sirainen<div class="titlepage"><div><div><h3 class="title">
55e04e5659b27c520633835d3f04e2eca7f21117Timo Sirainen<a name="journal"></a>The journal file</h3></div></div></div>
fa2433aebcf3fccfa30ca9eed9b1a9166cf92ee2Timo Sirainen All changes made to a zone using dynamic update are stored
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen in the zone's journal file. This file is automatically created
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen by the server when the first dynamic update takes place.
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen The name of the journal file is formed by appending the extension
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen <code class="filename">.jnl</code> to the name of the
85779ec11f23eb8efeb8993b1e0b9aad62c4122aTimo Sirainen corresponding zone
85779ec11f23eb8efeb8993b1e0b9aad62c4122aTimo Sirainen file unless specifically overridden. The journal file is in a
85779ec11f23eb8efeb8993b1e0b9aad62c4122aTimo Sirainen binary format and should not be edited manually.
85779ec11f23eb8efeb8993b1e0b9aad62c4122aTimo Sirainen The server will also occasionally write ("dump")
85779ec11f23eb8efeb8993b1e0b9aad62c4122aTimo Sirainen the complete contents of the updated zone to its zone file.
85779ec11f23eb8efeb8993b1e0b9aad62c4122aTimo Sirainen This is not done immediately after
47e9fdee55c2074425cf0316f4f64fbbb790301cTimo Sirainen each dynamic update, because that would be too slow when a large
47e9fdee55c2074425cf0316f4f64fbbb790301cTimo Sirainen zone is updated frequently. Instead, the dump is delayed by
4da8c6cdefabd31262318c32da3c13de1d9ea953Timo Sirainen up to 15 minutes, allowing additional updates to take place.
7e95ba7f38b9b421287d36c6152f8a9e6b9f225bTimo Sirainen When a server is restarted after a shutdown or crash, it will replay
7e95ba7f38b9b421287d36c6152f8a9e6b9f225bTimo Sirainen the journal file to incorporate into the zone any updates that
608bdb7f008cd5cd332d727018a9e8173abec998Timo Sirainen place after the last zone dump.
30b849c26358317b4e25b19ced4b7deb55f59c0aTimo Sirainen Changes that result from incoming incremental zone transfers are
19cadcc25c26af7afea1355d78e20ad64eaad263Timo Sirainen journalled in a similar way.
d23dfc385f22d7a2c466d29501c9e0ce5a243deeTimo Sirainen The zone files of dynamic zones cannot normally be edited by
d23dfc385f22d7a2c466d29501c9e0ce5a243deeTimo Sirainen hand because they are not guaranteed to contain the most recent
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen dynamic changes — those are only in the journal file.
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen The only way to ensure that the zone file of a dynamic zone
24ff040448e018738515f7bfcc6f1a6e5d08c10dSergey Kitov is up to date is to run <span><strong class="command">rndc stop</strong></span>.
24ff040448e018738515f7bfcc6f1a6e5d08c10dSergey Kitov If you have to make changes to a dynamic zone
24ff040448e018738515f7bfcc6f1a6e5d08c10dSergey Kitov manually, the following procedure will work: Disable dynamic updates
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen to the zone using
8d3278a82b964217d95c340ec6f82037cdc59d19Timo Sirainen <span><strong class="command">rndc freeze <em class="replaceable"><code>zone</code></em></strong></span>.
<span><strong class="command">rndc thaw <em class="replaceable"><code>zone</code></em></strong></span>
except queries for <code class="filename">site1.internal</code>, <code class="filename">site2.internal</code>, <code class="filename">site1.example.com</code>,
for <code class="filename">site1.example.com</code>, <code class="filename">site2.example.com</code>,<span class="emphasis"><em></em></span> <code class="filename">site1.internal</code>,
To protect the <code class="filename">site1.internal</code> and <code class="filename">site2.internal</code> domains,
be configured to serve the "public" version of the <code class="filename">site1</code> and <code class="filename">site2.example.com</code> zones.
and mail exchange (MX) records (<code class="filename">a.mx.example.com</code> and <code class="filename">b.mx.example.com</code>).
In addition, the public <code class="filename">site1</code> and <code class="filename">site2.example.com</code> zones
for information on how to configure your zone files, see <a href="Bv9ARM.ch03.html#sample_configuration" title="Sample Configurations">the section called “Sample Configurations”</a>.
zone "site1.example.com" { // sample master zone
zone "site2.example.com" { // sample slave zone
zone "site1.internal" {
zone "site2.internal" {
zone "site1.example.com" { // sample slave zone
zone "site2.example.com" {
A shared secret is generated to be shared between <span class="emphasis"><em>host1</em></span> and <span class="emphasis"><em>host2</em></span>.
<strong class="userinput"><code>dnssec-keygen -a hmac-md5 -b 128 -n HOST host1-host2.</code></strong>
Imagine <span class="emphasis"><em>host1</em></span> and <span class="emphasis"><em>host 2</em></span>
both servers. The following is added to each server's <code class="filename">named.conf</code> file:
be told when keys are to be used. The following is added to the <code class="filename">named.conf</code> file
for <span class="emphasis"><em>host1</em></span>, if the IP address of <span class="emphasis"><em>host2</em></span> is
to that address, the message will be signed with the specified key. <span class="emphasis"><em>host1</em></span> will
configuration file (with <span class="emphasis"><em>host1</em></span>'s address) for <span class="emphasis"><em>host2</em></span> to
<a href="Bv9ARM.ch06.html#dynamic_update_policies" title="Dynamic Update Policies">the section called “Dynamic Update Policies”</a>.
that the tools shipped with BIND 9.2.x and earlier are not compatible
<strong class="userinput"><code>dnssec-keygen -a RSASHA1 -b 768 -n ZONE child.example.</code></strong>
example.com. 257 3 5 "AwEAAaxPMcR2x0HbQV4WeZB6oEDX+r0QM65KbhTjrW1ZaARmPhEZZe
<a name="id2571955"></a>IPv6 Support in <acronym class="acronym">BIND</acronym> 9</h2></div></div></div>
see <a href="Bv9ARM.ch09.html#ipv6addresses" title="IPv6 addresses (AAAA)">the section called “IPv6 addresses (AAAA)”</a>.
$ORIGIN example.com.
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 14400 IN PTR host.example.com.