]> CyberLeo.Net >> Repos - FreeBSD/stable/9.git/blob - contrib/bind9/doc/arm/Bv9ARM.ch06.html
Update BIND to 9.9.7.
[FreeBSD/stable/9.git] / contrib / bind9 / doc / arm / Bv9ARM.ch06.html
1 <!--
2  - Copyright (C) 2004-2015 Internet Systems Consortium, Inc. ("ISC")
3  - Copyright (C) 2000-2003 Internet Software Consortium.
4  - 
5  - Permission to use, copy, modify, and/or distribute this software for any
6  - purpose with or without fee is hereby granted, provided that the above
7  - copyright notice and this permission notice appear in all copies.
8  - 
9  - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
10  - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
11  - AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
12  - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
13  - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
14  - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
15  - PERFORMANCE OF THIS SOFTWARE.
16 -->
17 <!-- $Id$ -->
18 <html>
19 <head>
20 <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
21 <title>Chapter 6. BIND 9 Configuration Reference</title>
22 <meta name="generator" content="DocBook XSL Stylesheets V1.71.1">
23 <link rel="start" href="Bv9ARM.html" title="BIND 9 Administrator Reference Manual">
24 <link rel="up" href="Bv9ARM.html" title="BIND 9 Administrator Reference Manual">
25 <link rel="prev" href="Bv9ARM.ch05.html" title="Chapter 5. The BIND 9 Lightweight Resolver">
26 <link rel="next" href="Bv9ARM.ch07.html" title="Chapter 7. BIND 9 Security Considerations">
27 </head>
28 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
29 <div class="navheader">
30 <table width="100%" summary="Navigation header">
31 <tr><th colspan="3" align="center">Chapter 6. <acronym class="acronym">BIND</acronym> 9 Configuration Reference</th></tr>
32 <tr>
33 <td width="20%" align="left">
34 <a accesskey="p" href="Bv9ARM.ch05.html">Prev</a> </td>
35 <th width="60%" align="center"> </th>
36 <td width="20%" align="right"> <a accesskey="n" href="Bv9ARM.ch07.html">Next</a>
37 </td>
38 </tr>
39 </table>
40 <hr>
41 </div>
42 <div class="chapter" lang="en">
43 <div class="titlepage"><div><div><h2 class="title">
44 <a name="Bv9ARM.ch06"></a>Chapter 6. <acronym class="acronym">BIND</acronym> 9 Configuration Reference</h2></div></div></div>
45 <div class="toc">
46 <p><b>Table of Contents</b></p>
47 <dl>
48 <dt><span class="sect1"><a href="Bv9ARM.ch06.html#configuration_file_elements">Configuration File Elements</a></span></dt>
49 <dd><dl>
50 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#address_match_lists">Address Match Lists</a></span></dt>
51 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2573374">Comment Syntax</a></span></dt>
52 </dl></dd>
53 <dt><span class="sect1"><a href="Bv9ARM.ch06.html#Configuration_File_Grammar">Configuration File Grammar</a></span></dt>
54 <dd><dl>
55 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2574035"><span><strong class="command">acl</strong></span> Statement Grammar</a></span></dt>
56 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#acl"><span><strong class="command">acl</strong></span> Statement Definition and
57           Usage</a></span></dt>
58 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2574225"><span><strong class="command">controls</strong></span> Statement Grammar</a></span></dt>
59 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#controls_statement_definition_and_usage"><span><strong class="command">controls</strong></span> Statement Definition and
60           Usage</a></span></dt>
61 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2574584"><span><strong class="command">include</strong></span> Statement Grammar</a></span></dt>
62 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2574601"><span><strong class="command">include</strong></span> Statement Definition and
63           Usage</a></span></dt>
64 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2574761"><span><strong class="command">key</strong></span> Statement Grammar</a></span></dt>
65 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2574785"><span><strong class="command">key</strong></span> Statement Definition and Usage</a></span></dt>
66 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2574875"><span><strong class="command">logging</strong></span> Statement Grammar</a></span></dt>
67 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2575001"><span><strong class="command">logging</strong></span> Statement Definition and
68           Usage</a></span></dt>
69 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2577168"><span><strong class="command">lwres</strong></span> Statement Grammar</a></span></dt>
70 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2577241"><span><strong class="command">lwres</strong></span> Statement Definition and Usage</a></span></dt>
71 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2577305"><span><strong class="command">masters</strong></span> Statement Grammar</a></span></dt>
72 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2577417"><span><strong class="command">masters</strong></span> Statement Definition and
73           Usage</a></span></dt>
74 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2577438"><span><strong class="command">options</strong></span> Statement Grammar</a></span></dt>
75 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#options"><span><strong class="command">options</strong></span> Statement Definition and
76           Usage</a></span></dt>
77 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#server_statement_grammar"><span><strong class="command">server</strong></span> Statement Grammar</a></span></dt>
78 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#server_statement_definition_and_usage"><span><strong class="command">server</strong></span> Statement Definition and
79             Usage</a></span></dt>
80 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#statschannels"><span><strong class="command">statistics-channels</strong></span> Statement Grammar</a></span></dt>
81 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2590489"><span><strong class="command">statistics-channels</strong></span> Statement Definition and
82             Usage</a></span></dt>
83 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#trusted-keys"><span><strong class="command">trusted-keys</strong></span> Statement Grammar</a></span></dt>
84 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2590796"><span><strong class="command">trusted-keys</strong></span> Statement Definition
85             and Usage</a></span></dt>
86 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2590843"><span><strong class="command">managed-keys</strong></span> Statement Grammar</a></span></dt>
87 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#managed-keys"><span><strong class="command">managed-keys</strong></span> Statement Definition
88             and Usage</a></span></dt>
89 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#view_statement_grammar"><span><strong class="command">view</strong></span> Statement Grammar</a></span></dt>
90 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2591278"><span><strong class="command">view</strong></span> Statement Definition and Usage</a></span></dt>
91 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#zone_statement_grammar"><span><strong class="command">zone</strong></span>
92             Statement Grammar</a></span></dt>
93 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2592987"><span><strong class="command">zone</strong></span> Statement Definition and Usage</a></span></dt>
94 </dl></dd>
95 <dt><span class="sect1"><a href="Bv9ARM.ch06.html#id2596605">Zone File</a></span></dt>
96 <dd><dl>
97 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#types_of_resource_records_and_when_to_use_them">Types of Resource Records and When to Use Them</a></span></dt>
98 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2598768">Discussion of MX Records</a></span></dt>
99 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#Setting_TTLs">Setting TTLs</a></span></dt>
100 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2599451">Inverse Mapping in IPv4</a></span></dt>
101 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2599578">Other Zone File Directives</a></span></dt>
102 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#id2599851"><acronym class="acronym">BIND</acronym> Master File Extension: the  <span><strong class="command">$GENERATE</strong></span> Directive</a></span></dt>
103 <dt><span class="sect2"><a href="Bv9ARM.ch06.html#zonefile_format">Additional File Formats</a></span></dt>
104 </dl></dd>
105 <dt><span class="sect1"><a href="Bv9ARM.ch06.html#statistics">BIND9 Statistics</a></span></dt>
106 <dd><dl><dt><span class="sect2"><a href="Bv9ARM.ch06.html#statistics_counters">Statistics Counters</a></span></dt></dl></dd>
107 </dl>
108 </div>
109 <p>
110       <acronym class="acronym">BIND</acronym> 9 configuration is broadly similar
111       to <acronym class="acronym">BIND</acronym> 8; however, there are a few new
112       areas
113       of configuration, such as views. <acronym class="acronym">BIND</acronym>
114       8 configuration files should work with few alterations in <acronym class="acronym">BIND</acronym>
115       9, although more complex configurations should be reviewed to check
116       if they can be more efficiently implemented using the new features
117       found in <acronym class="acronym">BIND</acronym> 9.
118     </p>
119 <p>
120       <acronym class="acronym">BIND</acronym> 4 configuration files can be
121       converted to the new format
122       using the shell script
123       <code class="filename">contrib/named-bootconf/named-bootconf.sh</code>.
124     </p>
125 <div class="sect1" lang="en">
126 <div class="titlepage"><div><div><h2 class="title" style="clear: both">
127 <a name="configuration_file_elements"></a>Configuration File Elements</h2></div></div></div>
128 <p>
129         Following is a list of elements used throughout the <acronym class="acronym">BIND</acronym> configuration
130         file documentation:
131       </p>
132 <div class="informaltable"><table border="1">
133 <colgroup>
134 <col>
135 <col>
136 </colgroup>
137 <tbody>
138 <tr>
139 <td>
140                 <p>
141                   <code class="varname">acl_name</code>
142                 </p>
143               </td>
144 <td>
145                 <p>
146                   The name of an <code class="varname">address_match_list</code> as
147                   defined by the <span><strong class="command">acl</strong></span> statement.
148                 </p>
149               </td>
150 </tr>
151 <tr>
152 <td>
153                 <p>
154                   <code class="varname">address_match_list</code>
155                 </p>
156               </td>
157 <td>
158                 <p>
159                   A list of one or more
160                   <code class="varname">ip_addr</code>,
161                   <code class="varname">ip_prefix</code>, <code class="varname">key_id</code>,
162                   or <code class="varname">acl_name</code> elements, see
163                   <a href="Bv9ARM.ch06.html#address_match_lists" title="Address Match Lists">the section called &#8220;Address Match Lists&#8221;</a>.
164                 </p>
165               </td>
166 </tr>
167 <tr>
168 <td>
169                 <p>
170                   <code class="varname">masters_list</code>
171                 </p>
172               </td>
173 <td>
174                 <p>
175                   A named list of one or more <code class="varname">ip_addr</code>
176                   with optional <code class="varname">key_id</code> and/or
177                   <code class="varname">ip_port</code>.
178                   A <code class="varname">masters_list</code> may include other
179                   <code class="varname">masters_lists</code>.
180                 </p>
181               </td>
182 </tr>
183 <tr>
184 <td>
185                 <p>
186                   <code class="varname">domain_name</code>
187                 </p>
188               </td>
189 <td>
190                 <p>
191                   A quoted string which will be used as
192                   a DNS name, for example "<code class="literal">my.test.domain</code>".
193                 </p>
194               </td>
195 </tr>
196 <tr>
197 <td>
198                 <p>
199                   <code class="varname">namelist</code>
200                 </p>
201               </td>
202 <td>
203                 <p>
204                   A list of one or more <code class="varname">domain_name</code>
205                   elements.
206                 </p>
207               </td>
208 </tr>
209 <tr>
210 <td>
211                 <p>
212                   <code class="varname">dotted_decimal</code>
213                 </p>
214               </td>
215 <td>
216                 <p>
217                   One to four integers valued 0 through
218                   255 separated by dots (`.'), such as <span><strong class="command">123</strong></span>,
219                   <span><strong class="command">45.67</strong></span> or <span><strong class="command">89.123.45.67</strong></span>.
220                 </p>
221               </td>
222 </tr>
223 <tr>
224 <td>
225                 <p>
226                   <code class="varname">ip4_addr</code>
227                 </p>
228               </td>
229 <td>
230                 <p>
231                   An IPv4 address with exactly four elements
232                   in <code class="varname">dotted_decimal</code> notation.
233                 </p>
234               </td>
235 </tr>
236 <tr>
237 <td>
238                 <p>
239                   <code class="varname">ip6_addr</code>
240                 </p>
241               </td>
242 <td>
243                 <p>
244                   An IPv6 address, such as <span><strong class="command">2001:db8::1234</strong></span>.
245                   IPv6 scoped addresses that have ambiguity on their
246                   scope zones must be disambiguated by an appropriate
247                   zone ID with the percent character (`%') as
248                   delimiter.  It is strongly recommended to use
249                   string zone names rather than numeric identifiers,
250                   in order to be robust against system configuration
251                   changes.  However, since there is no standard
252                   mapping for such names and identifier values,
253                   currently only interface names as link identifiers
254                   are supported, assuming one-to-one mapping between
255                   interfaces and links.  For example, a link-local
256                   address <span><strong class="command">fe80::1</strong></span> on the link
257                   attached to the interface <span><strong class="command">ne0</strong></span>
258                   can be specified as <span><strong class="command">fe80::1%ne0</strong></span>.
259                   Note that on most systems link-local addresses
260                   always have the ambiguity, and need to be
261                   disambiguated.
262                 </p>
263               </td>
264 </tr>
265 <tr>
266 <td>
267                 <p>
268                   <code class="varname">ip_addr</code>
269                 </p>
270               </td>
271 <td>
272                 <p>
273                   An <code class="varname">ip4_addr</code> or <code class="varname">ip6_addr</code>.
274                 </p>
275               </td>
276 </tr>
277 <tr>
278 <td>
279                 <p>
280                   <code class="varname">ip_port</code>
281                 </p>
282               </td>
283 <td>
284                 <p>
285                   An IP port <code class="varname">number</code>.
286                   The <code class="varname">number</code> is limited to 0
287                   through 65535, with values
288                   below 1024 typically restricted to use by processes running
289                   as root.
290                   In some cases, an asterisk (`*') character can be used as a
291                   placeholder to
292                   select a random high-numbered port.
293                 </p>
294               </td>
295 </tr>
296 <tr>
297 <td>
298                 <p>
299                   <code class="varname">ip_prefix</code>
300                 </p>
301               </td>
302 <td>
303                 <p>
304                   An IP network specified as an <code class="varname">ip_addr</code>,
305                   followed by a slash (`/') and then the number of bits in the
306                   netmask.
307                   Trailing zeros in a <code class="varname">ip_addr</code>
308                   may omitted.
309                   For example, <span><strong class="command">127/8</strong></span> is the
310                   network <span><strong class="command">127.0.0.0</strong></span> with
311                   netmask <span><strong class="command">255.0.0.0</strong></span> and <span><strong class="command">1.2.3.0/28</strong></span> is
312                   network <span><strong class="command">1.2.3.0</strong></span> with netmask <span><strong class="command">255.255.255.240</strong></span>.
313                 </p>
314                 <p>
315                   When specifying a prefix involving a IPv6 scoped address
316                   the scope may be omitted.  In that case the prefix will
317                   match packets from any scope.
318                 </p>
319               </td>
320 </tr>
321 <tr>
322 <td>
323                 <p>
324                   <code class="varname">key_id</code>
325                 </p>
326               </td>
327 <td>
328                 <p>
329                   A <code class="varname">domain_name</code> representing
330                   the name of a shared key, to be used for transaction
331                   security.
332                 </p>
333               </td>
334 </tr>
335 <tr>
336 <td>
337                 <p>
338                   <code class="varname">key_list</code>
339                 </p>
340               </td>
341 <td>
342                 <p>
343                   A list of one or more
344                   <code class="varname">key_id</code>s,
345                   separated by semicolons and ending with a semicolon.
346                 </p>
347               </td>
348 </tr>
349 <tr>
350 <td>
351                 <p>
352                   <code class="varname">number</code>
353                 </p>
354               </td>
355 <td>
356                 <p>
357                   A non-negative 32-bit integer
358                   (i.e., a number between 0 and 4294967295, inclusive).
359                   Its acceptable value might further
360                   be limited by the context in which it is used.
361                 </p>
362               </td>
363 </tr>
364 <tr>
365 <td>
366                 <p>
367                   <code class="varname">path_name</code>
368                 </p>
369               </td>
370 <td>
371                 <p>
372                   A quoted string which will be used as
373                   a pathname, such as <code class="filename">zones/master/my.test.domain</code>.
374                 </p>
375               </td>
376 </tr>
377 <tr>
378 <td>
379                 <p>
380                   <code class="varname">port_list</code>
381                 </p>
382               </td>
383 <td>
384                 <p>
385                   A list of an <code class="varname">ip_port</code> or a port
386                   range.
387                   A port range is specified in the form of
388                   <strong class="userinput"><code>range</code></strong> followed by
389                   two <code class="varname">ip_port</code>s,
390                   <code class="varname">port_low</code> and
391                   <code class="varname">port_high</code>, which represents
392                   port numbers from <code class="varname">port_low</code> through
393                   <code class="varname">port_high</code>, inclusive.
394                   <code class="varname">port_low</code> must not be larger than
395                   <code class="varname">port_high</code>.
396                   For example,
397                   <strong class="userinput"><code>range 1024 65535</code></strong> represents
398                   ports from 1024 through 65535.
399                   In either case an asterisk (`*') character is not
400                   allowed as a valid <code class="varname">ip_port</code>.
401                 </p>
402               </td>
403 </tr>
404 <tr>
405 <td>
406                 <p>
407                   <code class="varname">size_spec</code>
408                 </p>
409               </td>
410 <td>
411                 <p>
412                   A 64-bit unsigned integer, or the keywords
413                   <strong class="userinput"><code>unlimited</code></strong> or
414                   <strong class="userinput"><code>default</code></strong>.
415                 </p>
416                 <p>
417                   Integers may take values
418                   0 &lt;= value &lt;= 18446744073709551615, though
419                   certain parameters
420                   (such as <span><strong class="command">max-journal-size</strong></span>) may
421                   use a more limited range within these extremes.
422                   In most cases, setting a value to 0 does not
423                   literally mean zero; it means "undefined" or
424                   "as big as possible", depending on the context.
425                   See the explanations of particular parameters
426                   that use <code class="varname">size_spec</code>
427                   for details on how they interpret its use. 
428                 </p>
429                 <p>
430                   Numeric values can optionally be followed by a
431                   scaling factor:
432                   <strong class="userinput"><code>K</code></strong> or <strong class="userinput"><code>k</code></strong>
433                   for kilobytes,
434                   <strong class="userinput"><code>M</code></strong> or <strong class="userinput"><code>m</code></strong>
435                   for megabytes, and
436                   <strong class="userinput"><code>G</code></strong> or <strong class="userinput"><code>g</code></strong>
437                   for gigabytes, which scale by 1024, 1024*1024, and
438                   1024*1024*1024 respectively.
439                 </p>
440                 <p>
441                   <code class="varname">unlimited</code> generally means
442                   "as big as possible", though in certain contexts,
443                   (including <code class="option">max-cache-size</code>), it may
444                   mean the largest possible 32-bit unsigned integer
445                   (0xffffffff); this distinction can be important when
446                   dealing with larger quantities. 
447                   <code class="varname">unlimited</code> is usually the best way
448                   to safely set a very large number.
449                 </p>
450                 <p>
451                   <code class="varname">default</code> 
452                   uses the limit that was in force when the server was started.
453                 </p>
454               </td>
455 </tr>
456 <tr>
457 <td>
458                 <p>
459                   <code class="varname">yes_or_no</code>
460                 </p>
461               </td>
462 <td>
463                 <p>
464                   Either <strong class="userinput"><code>yes</code></strong> or <strong class="userinput"><code>no</code></strong>.
465                   The words <strong class="userinput"><code>true</code></strong> and <strong class="userinput"><code>false</code></strong> are
466                   also accepted, as are the numbers <strong class="userinput"><code>1</code></strong>
467                   and <strong class="userinput"><code>0</code></strong>.
468                 </p>
469               </td>
470 </tr>
471 <tr>
472 <td>
473                 <p>
474                   <code class="varname">dialup_option</code>
475                 </p>
476               </td>
477 <td>
478                 <p>
479                   One of <strong class="userinput"><code>yes</code></strong>,
480                   <strong class="userinput"><code>no</code></strong>, <strong class="userinput"><code>notify</code></strong>,
481                   <strong class="userinput"><code>notify-passive</code></strong>, <strong class="userinput"><code>refresh</code></strong> or
482                   <strong class="userinput"><code>passive</code></strong>.
483                   When used in a zone, <strong class="userinput"><code>notify-passive</code></strong>,
484                   <strong class="userinput"><code>refresh</code></strong>, and <strong class="userinput"><code>passive</code></strong>
485                   are restricted to slave and stub zones.
486                 </p>
487               </td>
488 </tr>
489 </tbody>
490 </table></div>
491 <div class="sect2" lang="en">
492 <div class="titlepage"><div><div><h3 class="title">
493 <a name="address_match_lists"></a>Address Match Lists</h3></div></div></div>
494 <div class="sect3" lang="en">
495 <div class="titlepage"><div><div><h4 class="title">
496 <a name="id2573073"></a>Syntax</h4></div></div></div>
497 <pre class="programlisting"><code class="varname">address_match_list</code> = address_match_list_element ;
498   [<span class="optional"> address_match_list_element; ... </span>]
499 <code class="varname">address_match_list_element</code> = [<span class="optional"> ! </span>] (ip_address [<span class="optional">/length</span>] |
500    key key_id | acl_name | { address_match_list } )
501 </pre>
502 </div>
503 <div class="sect3" lang="en">
504 <div class="titlepage"><div><div><h4 class="title">
505 <a name="id2573100"></a>Definition and Usage</h4></div></div></div>
506 <p>
507             Address match lists are primarily used to determine access
508             control for various server operations. They are also used in
509             the <span><strong class="command">listen-on</strong></span> and <span><strong class="command">sortlist</strong></span>
510             statements. The elements which constitute an address match
511             list can be any of the following:
512           </p>
513 <div class="itemizedlist"><ul type="disc">
514 <li>an IP address (IPv4 or IPv6)</li>
515 <li>an IP prefix (in `/' notation)</li>
516 <li>
517                 a key ID, as defined by the <span><strong class="command">key</strong></span>
518                 statement
519               </li>
520 <li>the name of an address match list defined with
521                 the <span><strong class="command">acl</strong></span> statement
522               </li>
523 <li>a nested address match list enclosed in braces</li>
524 </ul></div>
525 <p>
526             Elements can be negated with a leading exclamation mark (`!'),
527             and the match list names "any", "none", "localhost", and
528             "localnets" are predefined. More information on those names
529             can be found in the description of the acl statement.
530           </p>
531 <p>
532             The addition of the key clause made the name of this syntactic
533             element something of a misnomer, since security keys can be used
534             to validate access without regard to a host or network address.
535             Nonetheless, the term "address match list" is still used
536             throughout the documentation.
537           </p>
538 <p>
539             When a given IP address or prefix is compared to an address
540             match list, the comparison takes place in approximately O(1)
541             time.  However, key comparisons require that the list of keys
542             be traversed until a matching key is found, and therefore may
543             be somewhat slower.
544           </p>
545 <p>
546             The interpretation of a match depends on whether the list is being
547             used for access control, defining <span><strong class="command">listen-on</strong></span> ports, or in a
548             <span><strong class="command">sortlist</strong></span>, and whether the element was negated.
549           </p>
550 <p>
551             When used as an access control list, a non-negated match
552             allows access and a negated match denies access. If
553             there is no match, access is denied. The clauses
554             <span><strong class="command">allow-notify</strong></span>,
555             <span><strong class="command">allow-recursion</strong></span>,
556             <span><strong class="command">allow-recursion-on</strong></span>,
557             <span><strong class="command">allow-query</strong></span>,
558             <span><strong class="command">allow-query-on</strong></span>,
559             <span><strong class="command">allow-query-cache</strong></span>,
560             <span><strong class="command">allow-query-cache-on</strong></span>,
561             <span><strong class="command">allow-transfer</strong></span>,
562             <span><strong class="command">allow-update</strong></span>,
563             <span><strong class="command">allow-update-forwarding</strong></span>, and
564             <span><strong class="command">blackhole</strong></span> all use address match
565             lists.  Similarly, the <span><strong class="command">listen-on</strong></span> option will cause the
566             server to refuse queries on any of the machine's
567             addresses which do not match the list.
568           </p>
569 <p>
570             Order of insertion is significant.  If more than one element
571             in an ACL is found to match a given IP address or prefix,
572             preference will be given to the one that came
573             <span class="emphasis"><em>first</em></span> in the ACL definition.
574             Because of this first-match behavior, an element that
575             defines a subset of another element in the list should
576             come before the broader element, regardless of whether
577             either is negated. For example, in
578             <span><strong class="command">1.2.3/24; ! 1.2.3.13;</strong></span>
579             the 1.2.3.13 element is completely useless because the
580             algorithm will match any lookup for 1.2.3.13 to the 1.2.3/24
581             element.  Using <span><strong class="command">! 1.2.3.13; 1.2.3/24</strong></span> fixes
582             that problem by having 1.2.3.13 blocked by the negation, but
583             all other 1.2.3.* hosts fall through.
584           </p>
585 </div>
586 </div>
587 <div class="sect2" lang="en">
588 <div class="titlepage"><div><div><h3 class="title">
589 <a name="id2573374"></a>Comment Syntax</h3></div></div></div>
590 <p>
591           The <acronym class="acronym">BIND</acronym> 9 comment syntax allows for
592           comments to appear
593           anywhere that whitespace may appear in a <acronym class="acronym">BIND</acronym> configuration
594           file. To appeal to programmers of all kinds, they can be written
595           in the C, C++, or shell/perl style.
596         </p>
597 <div class="sect3" lang="en">
598 <div class="titlepage"><div><div><h4 class="title">
599 <a name="id2573458"></a>Syntax</h4></div></div></div>
600 <p>
601             </p>
602 <pre class="programlisting">/* This is a <acronym class="acronym">BIND</acronym> comment as in C */</pre>
603 <p>
604             </p>
605 <pre class="programlisting">// This is a <acronym class="acronym">BIND</acronym> comment as in C++</pre>
606 <p>
607             </p>
608 <pre class="programlisting"># This is a <acronym class="acronym">BIND</acronym> comment as in common UNIX shells
609 # and perl</pre>
610 <p>
611           </p>
612 </div>
613 <div class="sect3" lang="en">
614 <div class="titlepage"><div><div><h4 class="title">
615 <a name="id2573488"></a>Definition and Usage</h4></div></div></div>
616 <p>
617             Comments may appear anywhere that whitespace may appear in
618             a <acronym class="acronym">BIND</acronym> configuration file.
619           </p>
620 <p>
621             C-style comments start with the two characters /* (slash,
622             star) and end with */ (star, slash). Because they are completely
623             delimited with these characters, they can be used to comment only
624             a portion of a line or to span multiple lines.
625           </p>
626 <p>
627             C-style comments cannot be nested. For example, the following
628             is not valid because the entire comment ends with the first */:
629           </p>
630 <p>
631
632 </p>
633 <pre class="programlisting">/* This is the start of a comment.
634    This is still part of the comment.
635 /* This is an incorrect attempt at nesting a comment. */
636    This is no longer in any comment. */
637 </pre>
638 <p>
639
640           </p>
641 <p>
642             C++-style comments start with the two characters // (slash,
643             slash) and continue to the end of the physical line. They cannot
644             be continued across multiple physical lines; to have one logical
645             comment span multiple lines, each line must use the // pair.
646             For example:
647           </p>
648 <p>
649
650 </p>
651 <pre class="programlisting">// This is the start of a comment.  The next line
652 // is a new comment, even though it is logically
653 // part of the previous comment.
654 </pre>
655 <p>
656
657           </p>
658 <p>
659             Shell-style (or perl-style, if you prefer) comments start
660             with the character <code class="literal">#</code> (number sign)
661             and continue to the end of the
662             physical line, as in C++ comments.
663             For example:
664           </p>
665 <p>
666
667 </p>
668 <pre class="programlisting"># This is the start of a comment.  The next line
669 # is a new comment, even though it is logically
670 # part of the previous comment.
671 </pre>
672 <p>
673
674           </p>
675 <div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
676 <h3 class="title">Warning</h3>
677 <p>
678               You cannot use the semicolon (`;') character
679               to start a comment such as you would in a zone file. The
680               semicolon indicates the end of a configuration
681               statement.
682             </p>
683 </div>
684 </div>
685 </div>
686 </div>
687 <div class="sect1" lang="en">
688 <div class="titlepage"><div><div><h2 class="title" style="clear: both">
689 <a name="Configuration_File_Grammar"></a>Configuration File Grammar</h2></div></div></div>
690 <p>
691         A <acronym class="acronym">BIND</acronym> 9 configuration consists of
692         statements and comments.
693         Statements end with a semicolon. Statements and comments are the
694         only elements that can appear without enclosing braces. Many
695         statements contain a block of sub-statements, which are also
696         terminated with a semicolon.
697       </p>
698 <p>
699         The following statements are supported:
700       </p>
701 <div class="informaltable"><table border="1">
702 <colgroup>
703 <col>
704 <col>
705 </colgroup>
706 <tbody>
707 <tr>
708 <td>
709                 <p><span><strong class="command">acl</strong></span></p>
710               </td>
711 <td>
712                 <p>
713                   defines a named IP address
714                   matching list, for access control and other uses.
715                 </p>
716               </td>
717 </tr>
718 <tr>
719 <td>
720                 <p><span><strong class="command">controls</strong></span></p>
721               </td>
722 <td>
723                 <p>
724                   declares control channels to be used
725                   by the <span><strong class="command">rndc</strong></span> utility.
726                 </p>
727               </td>
728 </tr>
729 <tr>
730 <td>
731                 <p><span><strong class="command">include</strong></span></p>
732               </td>
733 <td>
734                 <p>
735                   includes a file.
736                 </p>
737               </td>
738 </tr>
739 <tr>
740 <td>
741                 <p><span><strong class="command">key</strong></span></p>
742               </td>
743 <td>
744                 <p>
745                   specifies key information for use in
746                   authentication and authorization using TSIG.
747                 </p>
748               </td>
749 </tr>
750 <tr>
751 <td>
752                 <p><span><strong class="command">logging</strong></span></p>
753               </td>
754 <td>
755                 <p>
756                   specifies what the server logs, and where
757                   the log messages are sent.
758                 </p>
759               </td>
760 </tr>
761 <tr>
762 <td>
763                 <p><span><strong class="command">lwres</strong></span></p>
764               </td>
765 <td>
766                 <p>
767                   configures <span><strong class="command">named</strong></span> to
768                   also act as a light-weight resolver daemon (<span><strong class="command">lwresd</strong></span>).
769                 </p>
770               </td>
771 </tr>
772 <tr>
773 <td>
774                 <p><span><strong class="command">masters</strong></span></p>
775               </td>
776 <td>
777                 <p>
778                   defines a named masters list for
779                   inclusion in stub and slave zones'
780                   <span><strong class="command">masters</strong></span> or 
781                   <span><strong class="command">also-notify</strong></span> lists.
782                 </p>
783               </td>
784 </tr>
785 <tr>
786 <td>
787                 <p><span><strong class="command">options</strong></span></p>
788               </td>
789 <td>
790                 <p>
791                   controls global server configuration
792                   options and sets defaults for other statements.
793                 </p>
794               </td>
795 </tr>
796 <tr>
797 <td>
798                 <p><span><strong class="command">server</strong></span></p>
799               </td>
800 <td>
801                 <p>
802                   sets certain configuration options on
803                   a per-server basis.
804                 </p>
805               </td>
806 </tr>
807 <tr>
808 <td>
809                 <p><span><strong class="command">statistics-channels</strong></span></p>
810               </td>
811 <td>
812                 <p>
813                   declares communication channels to get access to
814                   <span><strong class="command">named</strong></span> statistics.
815                 </p>
816               </td>
817 </tr>
818 <tr>
819 <td>
820                 <p><span><strong class="command">trusted-keys</strong></span></p>
821               </td>
822 <td>
823                 <p>
824                   defines trusted DNSSEC keys.
825                 </p>
826               </td>
827 </tr>
828 <tr>
829 <td>
830                 <p><span><strong class="command">managed-keys</strong></span></p>
831               </td>
832 <td>
833                 <p>
834                   lists DNSSEC keys to be kept up to date
835                   using RFC 5011 trust anchor maintenance.
836                 </p>
837               </td>
838 </tr>
839 <tr>
840 <td>
841                 <p><span><strong class="command">view</strong></span></p>
842               </td>
843 <td>
844                 <p>
845                   defines a view.
846                 </p>
847               </td>
848 </tr>
849 <tr>
850 <td>
851                 <p><span><strong class="command">zone</strong></span></p>
852               </td>
853 <td>
854                 <p>
855                   defines a zone.
856                 </p>
857               </td>
858 </tr>
859 </tbody>
860 </table></div>
861 <p>
862         The <span><strong class="command">logging</strong></span> and
863         <span><strong class="command">options</strong></span> statements may only occur once
864         per
865         configuration.
866       </p>
867 <div class="sect2" lang="en">
868 <div class="titlepage"><div><div><h3 class="title">
869 <a name="id2574035"></a><span><strong class="command">acl</strong></span> Statement Grammar</h3></div></div></div>
870 <pre class="programlisting"><span><strong class="command">acl</strong></span> acl-name {
871     address_match_list
872 };
873 </pre>
874 </div>
875 <div class="sect2" lang="en">
876 <div class="titlepage"><div><div><h3 class="title">
877 <a name="acl"></a><span><strong class="command">acl</strong></span> Statement Definition and
878           Usage</h3></div></div></div>
879 <p>
880           The <span><strong class="command">acl</strong></span> statement assigns a symbolic
881           name to an address match list. It gets its name from a primary
882           use of address match lists: Access Control Lists (ACLs).
883         </p>
884 <p>
885           The following ACLs are built-in:
886         </p>
887 <div class="informaltable"><table border="1">
888 <colgroup>
889 <col>
890 <col>
891 </colgroup>
892 <tbody>
893 <tr>
894 <td>
895                   <p><span><strong class="command">any</strong></span></p>
896                 </td>
897 <td>
898                   <p>
899                     Matches all hosts.
900                   </p>
901                 </td>
902 </tr>
903 <tr>
904 <td>
905                   <p><span><strong class="command">none</strong></span></p>
906                 </td>
907 <td>
908                   <p>
909                     Matches no hosts.
910                   </p>
911                 </td>
912 </tr>
913 <tr>
914 <td>
915                   <p><span><strong class="command">localhost</strong></span></p>
916                 </td>
917 <td>
918                   <p>
919                     Matches the IPv4 and IPv6 addresses of all network
920                     interfaces on the system.  When addresses are
921                     added or removed, the <span><strong class="command">localhost</strong></span>
922                     ACL element is updated to reflect the changes.
923                   </p>
924                 </td>
925 </tr>
926 <tr>
927 <td>
928                   <p><span><strong class="command">localnets</strong></span></p>
929                 </td>
930 <td>
931                   <p>
932                     Matches any host on an IPv4 or IPv6 network
933                     for which the system has an interface.
934                     When addresses are added or removed,
935                     the <span><strong class="command">localnets</strong></span>
936                     ACL element is updated to reflect the changes.
937                     Some systems do not provide a way to determine the prefix
938                     lengths of
939                     local IPv6 addresses.
940                     In such a case, <span><strong class="command">localnets</strong></span>
941                     only matches the local
942                     IPv6 addresses, just like <span><strong class="command">localhost</strong></span>.
943                   </p>
944                 </td>
945 </tr>
946 </tbody>
947 </table></div>
948 </div>
949 <div class="sect2" lang="en">
950 <div class="titlepage"><div><div><h3 class="title">
951 <a name="id2574225"></a><span><strong class="command">controls</strong></span> Statement Grammar</h3></div></div></div>
952 <pre class="programlisting"><span><strong class="command">controls</strong></span> {
953    [ inet ( ip_addr | * ) [ port ip_port ]
954                 allow { <em class="replaceable"><code> address_match_list </code></em> }
955                 keys { <em class="replaceable"><code>key_list</code></em> }; ]
956    [ inet ...; ]
957    [ unix <em class="replaceable"><code>path</code></em> perm <em class="replaceable"><code>number</code></em> owner <em class="replaceable"><code>number</code></em> group <em class="replaceable"><code>number</code></em>
958      keys { <em class="replaceable"><code>key_list</code></em> }; ]
959    [ unix ...; ]
960 };
961 </pre>
962 </div>
963 <div class="sect2" lang="en">
964 <div class="titlepage"><div><div><h3 class="title">
965 <a name="controls_statement_definition_and_usage"></a><span><strong class="command">controls</strong></span> Statement Definition and
966           Usage</h3></div></div></div>
967 <p>
968           The <span><strong class="command">controls</strong></span> statement declares control
969           channels to be used by system administrators to control the
970           operation of the name server. These control channels are
971           used by the <span><strong class="command">rndc</strong></span> utility to send
972           commands to and retrieve non-DNS results from a name server.
973         </p>
974 <p>
975           An <span><strong class="command">inet</strong></span> control channel is a TCP socket
976           listening at the specified <span><strong class="command">ip_port</strong></span> on the
977           specified <span><strong class="command">ip_addr</strong></span>, which can be an IPv4 or IPv6
978           address.  An <span><strong class="command">ip_addr</strong></span> of <code class="literal">*</code> (asterisk) is
979           interpreted as the IPv4 wildcard address; connections will be
980           accepted on any of the system's IPv4 addresses.
981           To listen on the IPv6 wildcard address,
982           use an <span><strong class="command">ip_addr</strong></span> of <code class="literal">::</code>.
983           If you will only use <span><strong class="command">rndc</strong></span> on the local host,
984           using the loopback address (<code class="literal">127.0.0.1</code>
985           or <code class="literal">::1</code>) is recommended for maximum security.
986         </p>
987 <p>
988           If no port is specified, port 953 is used. The asterisk
989           "<code class="literal">*</code>" cannot be used for <span><strong class="command">ip_port</strong></span>.
990         </p>
991 <p>
992           The ability to issue commands over the control channel is
993           restricted by the <span><strong class="command">allow</strong></span> and
994           <span><strong class="command">keys</strong></span> clauses.
995           Connections to the control channel are permitted based on the
996           <span><strong class="command">address_match_list</strong></span>.  This is for simple
997           IP address based filtering only; any <span><strong class="command">key_id</strong></span>
998           elements of the <span><strong class="command">address_match_list</strong></span>
999           are ignored.
1000         </p>
1001 <p>
1002           A <span><strong class="command">unix</strong></span> control channel is a UNIX domain
1003           socket listening at the specified path in the file system.
1004           Access to the socket is specified by the <span><strong class="command">perm</strong></span>,
1005           <span><strong class="command">owner</strong></span> and <span><strong class="command">group</strong></span> clauses.
1006           Note on some platforms (SunOS and Solaris) the permissions
1007           (<span><strong class="command">perm</strong></span>) are applied to the parent directory
1008           as the permissions on the socket itself are ignored.
1009         </p>
1010 <p>
1011           The primary authorization mechanism of the command
1012           channel is the <span><strong class="command">key_list</strong></span>, which
1013           contains a list of <span><strong class="command">key_id</strong></span>s.
1014           Each <span><strong class="command">key_id</strong></span> in the <span><strong class="command">key_list</strong></span>
1015           is authorized to execute commands over the control channel.
1016           See <a href="Bv9ARM.ch03.html#rndc">Remote Name Daemon Control application</a> in <a href="Bv9ARM.ch03.html#admin_tools" title="Administrative Tools">the section called &#8220;Administrative Tools&#8221;</a>)
1017           for information about configuring keys in <span><strong class="command">rndc</strong></span>.
1018         </p>
1019 <p>
1020           If no <span><strong class="command">controls</strong></span> statement is present,
1021           <span><strong class="command">named</strong></span> will set up a default
1022           control channel listening on the loopback address 127.0.0.1
1023           and its IPv6 counterpart ::1.
1024           In this case, and also when the <span><strong class="command">controls</strong></span> statement
1025           is present but does not have a <span><strong class="command">keys</strong></span> clause,
1026           <span><strong class="command">named</strong></span> will attempt to load the command channel key
1027           from the file <code class="filename">rndc.key</code> in
1028           <code class="filename">/etc</code> (or whatever <code class="varname">sysconfdir</code>
1029           was specified as when <acronym class="acronym">BIND</acronym> was built).
1030           To create a <code class="filename">rndc.key</code> file, run
1031           <strong class="userinput"><code>rndc-confgen -a</code></strong>.
1032         </p>
1033 <p>
1034           The <code class="filename">rndc.key</code> feature was created to
1035           ease the transition of systems from <acronym class="acronym">BIND</acronym> 8,
1036           which did not have digital signatures on its command channel
1037           messages and thus did not have a <span><strong class="command">keys</strong></span> clause.
1038
1039           It makes it possible to use an existing <acronym class="acronym">BIND</acronym> 8
1040           configuration file in <acronym class="acronym">BIND</acronym> 9 unchanged,
1041           and still have <span><strong class="command">rndc</strong></span> work the same way
1042           <span><strong class="command">ndc</strong></span> worked in BIND 8, simply by executing the
1043           command <strong class="userinput"><code>rndc-confgen -a</code></strong> after BIND 9 is
1044           installed.
1045         </p>
1046 <p>
1047           Since the <code class="filename">rndc.key</code> feature
1048           is only intended to allow the backward-compatible usage of
1049           <acronym class="acronym">BIND</acronym> 8 configuration files, this
1050           feature does not
1051           have a high degree of configurability.  You cannot easily change
1052           the key name or the size of the secret, so you should make a
1053           <code class="filename">rndc.conf</code> with your own key if you
1054           wish to change
1055           those things.  The <code class="filename">rndc.key</code> file
1056           also has its
1057           permissions set such that only the owner of the file (the user that
1058           <span><strong class="command">named</strong></span> is running as) can access it.
1059           If you
1060           desire greater flexibility in allowing other users to access
1061           <span><strong class="command">rndc</strong></span> commands, then you need to create
1062           a
1063           <code class="filename">rndc.conf</code> file and make it group
1064           readable by a group
1065           that contains the users who should have access.
1066         </p>
1067 <p>
1068           To disable the command channel, use an empty
1069           <span><strong class="command">controls</strong></span> statement:
1070           <span><strong class="command">controls { };</strong></span>.
1071         </p>
1072 </div>
1073 <div class="sect2" lang="en">
1074 <div class="titlepage"><div><div><h3 class="title">
1075 <a name="id2574584"></a><span><strong class="command">include</strong></span> Statement Grammar</h3></div></div></div>
1076 <pre class="programlisting"><span><strong class="command">include</strong></span> <em class="replaceable"><code>filename</code></em>;</pre>
1077 </div>
1078 <div class="sect2" lang="en">
1079 <div class="titlepage"><div><div><h3 class="title">
1080 <a name="id2574601"></a><span><strong class="command">include</strong></span> Statement Definition and
1081           Usage</h3></div></div></div>
1082 <p>
1083           The <span><strong class="command">include</strong></span> statement inserts the
1084           specified file at the point where the <span><strong class="command">include</strong></span>
1085           statement is encountered. The <span><strong class="command">include</strong></span>
1086                 statement facilitates the administration of configuration
1087           files
1088           by permitting the reading or writing of some things but not
1089           others. For example, the statement could include private keys
1090           that are readable only by the name server.
1091         </p>
1092 </div>
1093 <div class="sect2" lang="en">
1094 <div class="titlepage"><div><div><h3 class="title">
1095 <a name="id2574761"></a><span><strong class="command">key</strong></span> Statement Grammar</h3></div></div></div>
1096 <pre class="programlisting"><span><strong class="command">key</strong></span> <em class="replaceable"><code>key_id</code></em> {
1097     algorithm <em class="replaceable"><code>string</code></em>;
1098     secret <em class="replaceable"><code>string</code></em>;
1099 };
1100 </pre>
1101 </div>
1102 <div class="sect2" lang="en">
1103 <div class="titlepage"><div><div><h3 class="title">
1104 <a name="id2574785"></a><span><strong class="command">key</strong></span> Statement Definition and Usage</h3></div></div></div>
1105 <p>
1106           The <span><strong class="command">key</strong></span> statement defines a shared
1107           secret key for use with TSIG (see <a href="Bv9ARM.ch04.html#tsig" title="TSIG">the section called &#8220;TSIG&#8221;</a>)
1108           or the command channel
1109           (see <a href="Bv9ARM.ch06.html#controls_statement_definition_and_usage" title="controls Statement Definition and
1110           Usage">the section called &#8220;<span><strong class="command">controls</strong></span> Statement Definition and
1111           Usage&#8221;</a>).
1112         </p>
1113 <p>
1114           The <span><strong class="command">key</strong></span> statement can occur at the
1115           top level
1116           of the configuration file or inside a <span><strong class="command">view</strong></span>
1117           statement.  Keys defined in top-level <span><strong class="command">key</strong></span>
1118           statements can be used in all views.  Keys intended for use in
1119           a <span><strong class="command">controls</strong></span> statement
1120           (see <a href="Bv9ARM.ch06.html#controls_statement_definition_and_usage" title="controls Statement Definition and
1121           Usage">the section called &#8220;<span><strong class="command">controls</strong></span> Statement Definition and
1122           Usage&#8221;</a>)
1123           must be defined at the top level.
1124         </p>
1125 <p>
1126           The <em class="replaceable"><code>key_id</code></em>, also known as the
1127           key name, is a domain name uniquely identifying the key. It can
1128           be used in a <span><strong class="command">server</strong></span>
1129           statement to cause requests sent to that
1130           server to be signed with this key, or in address match lists to
1131           verify that incoming requests have been signed with a key
1132           matching this name, algorithm, and secret.
1133         </p>
1134 <p>
1135           The <em class="replaceable"><code>algorithm_id</code></em> is a string
1136           that specifies a security/authentication algorithm.  Named
1137           supports <code class="literal">hmac-md5</code>,
1138           <code class="literal">hmac-sha1</code>, <code class="literal">hmac-sha224</code>,
1139           <code class="literal">hmac-sha256</code>, <code class="literal">hmac-sha384</code>
1140           and <code class="literal">hmac-sha512</code> TSIG authentication.
1141           Truncated hashes are supported by appending the minimum
1142           number of required bits preceded by a dash, e.g.
1143           <code class="literal">hmac-sha1-80</code>.  The
1144           <em class="replaceable"><code>secret_string</code></em> is the secret
1145           to be used by the algorithm, and is treated as a base-64
1146           encoded string.
1147         </p>
1148 </div>
1149 <div class="sect2" lang="en">
1150 <div class="titlepage"><div><div><h3 class="title">
1151 <a name="id2574875"></a><span><strong class="command">logging</strong></span> Statement Grammar</h3></div></div></div>
1152 <pre class="programlisting"><span><strong class="command">logging</strong></span> {
1153    [ <span><strong class="command">channel</strong></span> <em class="replaceable"><code>channel_name</code></em> {
1154      ( <span><strong class="command">file</strong></span> <em class="replaceable"><code>path_name</code></em>
1155          [ <span><strong class="command">versions</strong></span> ( <em class="replaceable"><code>number</code></em> | <span><strong class="command">unlimited</strong></span> ) ]
1156          [ <span><strong class="command">size</strong></span> <em class="replaceable"><code>size_spec</code></em> ]
1157        | <span><strong class="command">syslog</strong></span> <em class="replaceable"><code>syslog_facility</code></em>
1158        | <span><strong class="command">stderr</strong></span>
1159        | <span><strong class="command">null</strong></span> );
1160      [ <span><strong class="command">severity</strong></span> (<code class="option">critical</code> | <code class="option">error</code> | <code class="option">warning</code> | <code class="option">notice</code> |
1161                  <code class="option">info</code> | <code class="option">debug</code> [ <em class="replaceable"><code>level</code></em> ] | <code class="option">dynamic</code> ); ]
1162      [ <span><strong class="command">print-category</strong></span> <code class="option">yes</code> or <code class="option">no</code>; ]
1163      [ <span><strong class="command">print-severity</strong></span> <code class="option">yes</code> or <code class="option">no</code>; ]
1164      [ <span><strong class="command">print-time</strong></span> <code class="option">yes</code> or <code class="option">no</code>; ]
1165    }; ]
1166    [ <span><strong class="command">category</strong></span> <em class="replaceable"><code>category_name</code></em> {
1167      <em class="replaceable"><code>channel_name</code></em> ; [ <em class="replaceable"><code>channel_name</code></em> ; ... ]
1168    }; ]
1169    ...
1170 };
1171 </pre>
1172 </div>
1173 <div class="sect2" lang="en">
1174 <div class="titlepage"><div><div><h3 class="title">
1175 <a name="id2575001"></a><span><strong class="command">logging</strong></span> Statement Definition and
1176           Usage</h3></div></div></div>
1177 <p>
1178           The <span><strong class="command">logging</strong></span> statement configures a
1179           wide
1180           variety of logging options for the name server. Its <span><strong class="command">channel</strong></span> phrase
1181           associates output methods, format options and severity levels with
1182           a name that can then be used with the <span><strong class="command">category</strong></span> phrase
1183           to select how various classes of messages are logged.
1184         </p>
1185 <p>
1186           Only one <span><strong class="command">logging</strong></span> statement is used to
1187           define
1188           as many channels and categories as are wanted. If there is no <span><strong class="command">logging</strong></span> statement,
1189           the logging configuration will be:
1190         </p>
1191 <pre class="programlisting">logging {
1192      category default { default_syslog; default_debug; };
1193      category unmatched { null; };
1194 };
1195 </pre>
1196 <p>
1197           In <acronym class="acronym">BIND</acronym> 9, the logging configuration
1198           is only established when
1199           the entire configuration file has been parsed.  In <acronym class="acronym">BIND</acronym> 8, it was
1200           established as soon as the <span><strong class="command">logging</strong></span>
1201           statement
1202           was parsed. When the server is starting up, all logging messages
1203           regarding syntax errors in the configuration file go to the default
1204           channels, or to standard error if the "<code class="option">-g</code>" option
1205           was specified.
1206         </p>
1207 <div class="sect3" lang="en">
1208 <div class="titlepage"><div><div><h4 class="title">
1209 <a name="id2575053"></a>The <span><strong class="command">channel</strong></span> Phrase</h4></div></div></div>
1210 <p>
1211             All log output goes to one or more <span class="emphasis"><em>channels</em></span>;
1212             you can make as many of them as you want.
1213           </p>
1214 <p>
1215             Every channel definition must include a destination clause that
1216             says whether messages selected for the channel go to a file, to a
1217             particular syslog facility, to the standard error stream, or are
1218             discarded. It can optionally also limit the message severity level
1219             that will be accepted by the channel (the default is
1220             <span><strong class="command">info</strong></span>), and whether to include a
1221             <span><strong class="command">named</strong></span>-generated time stamp, the
1222             category name
1223             and/or severity level (the default is not to include any).
1224           </p>
1225 <p>
1226             The <span><strong class="command">null</strong></span> destination clause
1227             causes all messages sent to the channel to be discarded;
1228             in that case, other options for the channel are meaningless.
1229           </p>
1230 <p>
1231             The <span><strong class="command">file</strong></span> destination clause directs
1232             the channel
1233             to a disk file.  It can include limitations
1234             both on how large the file is allowed to become, and how many
1235             versions
1236             of the file will be saved each time the file is opened.
1237           </p>
1238 <p>
1239             If you use the <span><strong class="command">versions</strong></span> log file
1240             option, then
1241             <span><strong class="command">named</strong></span> will retain that many backup
1242             versions of the file by
1243             renaming them when opening.  For example, if you choose to keep
1244             three old versions
1245             of the file <code class="filename">lamers.log</code>, then just
1246             before it is opened
1247             <code class="filename">lamers.log.1</code> is renamed to
1248             <code class="filename">lamers.log.2</code>, <code class="filename">lamers.log.0</code> is renamed
1249             to <code class="filename">lamers.log.1</code>, and <code class="filename">lamers.log</code> is
1250             renamed to <code class="filename">lamers.log.0</code>.
1251             You can say <span><strong class="command">versions unlimited</strong></span> to
1252             not limit
1253             the number of versions.
1254             If a <span><strong class="command">size</strong></span> option is associated with
1255             the log file,
1256             then renaming is only done when the file being opened exceeds the
1257             indicated size.  No backup versions are kept by default; any
1258             existing
1259             log file is simply appended.
1260           </p>
1261 <p>
1262             The <span><strong class="command">size</strong></span> option for files is used
1263             to limit log
1264             growth. If the file ever exceeds the size, then <span><strong class="command">named</strong></span> will
1265             stop writing to the file unless it has a <span><strong class="command">versions</strong></span> option
1266             associated with it.  If backup versions are kept, the files are
1267             rolled as
1268             described above and a new one begun.  If there is no
1269             <span><strong class="command">versions</strong></span> option, no more data will
1270             be written to the log
1271             until some out-of-band mechanism removes or truncates the log to
1272             less than the
1273             maximum size.  The default behavior is not to limit the size of
1274             the
1275             file.
1276           </p>
1277 <p>
1278             Example usage of the <span><strong class="command">size</strong></span> and
1279             <span><strong class="command">versions</strong></span> options:
1280           </p>
1281 <pre class="programlisting">channel an_example_channel {
1282     file "example.log" versions 3 size 20m;
1283     print-time yes;
1284     print-category yes;
1285 };
1286 </pre>
1287 <p>
1288             The <span><strong class="command">syslog</strong></span> destination clause
1289             directs the
1290             channel to the system log.  Its argument is a
1291             syslog facility as described in the <span><strong class="command">syslog</strong></span> man
1292             page. Known facilities are <span><strong class="command">kern</strong></span>, <span><strong class="command">user</strong></span>,
1293             <span><strong class="command">mail</strong></span>, <span><strong class="command">daemon</strong></span>, <span><strong class="command">auth</strong></span>,
1294             <span><strong class="command">syslog</strong></span>, <span><strong class="command">lpr</strong></span>, <span><strong class="command">news</strong></span>,
1295             <span><strong class="command">uucp</strong></span>, <span><strong class="command">cron</strong></span>, <span><strong class="command">authpriv</strong></span>,
1296             <span><strong class="command">ftp</strong></span>, <span><strong class="command">local0</strong></span>, <span><strong class="command">local1</strong></span>,
1297             <span><strong class="command">local2</strong></span>, <span><strong class="command">local3</strong></span>, <span><strong class="command">local4</strong></span>,
1298             <span><strong class="command">local5</strong></span>, <span><strong class="command">local6</strong></span> and
1299             <span><strong class="command">local7</strong></span>, however not all facilities
1300             are supported on
1301             all operating systems.
1302             How <span><strong class="command">syslog</strong></span> will handle messages
1303             sent to
1304             this facility is described in the <span><strong class="command">syslog.conf</strong></span> man
1305             page. If you have a system which uses a very old version of <span><strong class="command">syslog</strong></span> that
1306             only uses two arguments to the <span><strong class="command">openlog()</strong></span> function,
1307             then this clause is silently ignored.
1308           </p>
1309 <p>
1310             On Windows machines syslog messages are directed to the EventViewer.
1311           </p>
1312 <p>
1313             The <span><strong class="command">severity</strong></span> clause works like <span><strong class="command">syslog</strong></span>'s
1314             "priorities", except that they can also be used if you are writing
1315             straight to a file rather than using <span><strong class="command">syslog</strong></span>.
1316             Messages which are not at least of the severity level given will
1317             not be selected for the channel; messages of higher severity
1318             levels
1319             will be accepted.
1320           </p>
1321 <p>
1322             If you are using <span><strong class="command">syslog</strong></span>, then the <span><strong class="command">syslog.conf</strong></span> priorities
1323             will also determine what eventually passes through. For example,
1324             defining a channel facility and severity as <span><strong class="command">daemon</strong></span> and <span><strong class="command">debug</strong></span> but
1325             only logging <span><strong class="command">daemon.warning</strong></span> via <span><strong class="command">syslog.conf</strong></span> will
1326             cause messages of severity <span><strong class="command">info</strong></span> and
1327             <span><strong class="command">notice</strong></span> to
1328             be dropped. If the situation were reversed, with <span><strong class="command">named</strong></span> writing
1329             messages of only <span><strong class="command">warning</strong></span> or higher,
1330             then <span><strong class="command">syslogd</strong></span> would
1331             print all messages it received from the channel.
1332           </p>
1333 <p>
1334             The <span><strong class="command">stderr</strong></span> destination clause
1335             directs the
1336             channel to the server's standard error stream.  This is intended
1337             for
1338             use when the server is running as a foreground process, for
1339             example
1340             when debugging a configuration.
1341           </p>
1342 <p>
1343             The server can supply extensive debugging information when
1344             it is in debugging mode. If the server's global debug level is
1345             greater
1346             than zero, then debugging mode will be active. The global debug
1347             level is set either by starting the <span><strong class="command">named</strong></span> server
1348             with the <code class="option">-d</code> flag followed by a positive integer,
1349             or by running <span><strong class="command">rndc trace</strong></span>.
1350             The global debug level
1351             can be set to zero, and debugging mode turned off, by running <span><strong class="command">rndc
1352 notrace</strong></span>. All debugging messages in the server have a debug
1353             level, and higher debug levels give more detailed output. Channels
1354             that specify a specific debug severity, for example:
1355           </p>
1356 <pre class="programlisting">channel specific_debug_level {
1357     file "foo";
1358     severity debug 3;
1359 };
1360 </pre>
1361 <p>
1362             will get debugging output of level 3 or less any time the
1363             server is in debugging mode, regardless of the global debugging
1364             level. Channels with <span><strong class="command">dynamic</strong></span>
1365             severity use the
1366             server's global debug level to determine what messages to print.
1367           </p>
1368 <p>
1369             If <span><strong class="command">print-time</strong></span> has been turned on,
1370             then
1371             the date and time will be logged. <span><strong class="command">print-time</strong></span> may
1372             be specified for a <span><strong class="command">syslog</strong></span> channel,
1373             but is usually
1374             pointless since <span><strong class="command">syslog</strong></span> also logs
1375             the date and
1376             time. If <span><strong class="command">print-category</strong></span> is
1377             requested, then the
1378             category of the message will be logged as well. Finally, if <span><strong class="command">print-severity</strong></span> is
1379             on, then the severity level of the message will be logged. The <span><strong class="command">print-</strong></span> options may
1380             be used in any combination, and will always be printed in the
1381             following
1382             order: time, category, severity. Here is an example where all
1383             three <span><strong class="command">print-</strong></span> options
1384             are on:
1385           </p>
1386 <p>
1387             <code class="computeroutput">28-Feb-2000 15:05:32.863 general: notice: running</code>
1388           </p>
1389 <p>
1390             There are four predefined channels that are used for
1391             <span><strong class="command">named</strong></span>'s default logging as follows.
1392             How they are
1393             used is described in <a href="Bv9ARM.ch06.html#the_category_phrase" title="The category Phrase">the section called &#8220;The <span><strong class="command">category</strong></span> Phrase&#8221;</a>.
1394           </p>
1395 <pre class="programlisting">channel default_syslog {
1396     // send to syslog's daemon facility
1397     syslog daemon;
1398     // only send priority info and higher
1399     severity info;
1400
1401 channel default_debug {
1402     // write to named.run in the working directory
1403     // Note: stderr is used instead of "named.run" if
1404     // the server is started with the '-f' option.
1405     file "named.run";
1406     // log at the server's current debug level
1407     severity dynamic;
1408 };
1409
1410 channel default_stderr {
1411     // writes to stderr
1412     stderr;
1413     // only send priority info and higher
1414     severity info;
1415 };
1416
1417 channel null {
1418    // toss anything sent to this channel
1419    null;
1420 };
1421 </pre>
1422 <p>
1423             The <span><strong class="command">default_debug</strong></span> channel has the
1424             special
1425             property that it only produces output when the server's debug
1426             level is
1427             nonzero.  It normally writes to a file called <code class="filename">named.run</code>
1428             in the server's working directory.
1429           </p>
1430 <p>
1431             For security reasons, when the "<code class="option">-u</code>"
1432             command line option is used, the <code class="filename">named.run</code> file
1433             is created only after <span><strong class="command">named</strong></span> has
1434             changed to the
1435             new UID, and any debug output generated while <span><strong class="command">named</strong></span> is
1436             starting up and still running as root is discarded.  If you need
1437             to capture this output, you must run the server with the "<code class="option">-g</code>"
1438             option and redirect standard error to a file.
1439           </p>
1440 <p>
1441             Once a channel is defined, it cannot be redefined. Thus you
1442             cannot alter the built-in channels directly, but you can modify
1443             the default logging by pointing categories at channels you have
1444             defined.
1445           </p>
1446 </div>
1447 <div class="sect3" lang="en">
1448 <div class="titlepage"><div><div><h4 class="title">
1449 <a name="the_category_phrase"></a>The <span><strong class="command">category</strong></span> Phrase</h4></div></div></div>
1450 <p>
1451             There are many categories, so you can send the logs you want
1452             to see wherever you want, without seeing logs you don't want. If
1453             you don't specify a list of channels for a category, then log
1454             messages
1455             in that category will be sent to the <span><strong class="command">default</strong></span> category
1456             instead. If you don't specify a default category, the following
1457             "default default" is used:
1458           </p>
1459 <pre class="programlisting">category default { default_syslog; default_debug; };
1460 </pre>
1461 <p>
1462             As an example, let's say you want to log security events to
1463             a file, but you also want keep the default logging behavior. You'd
1464             specify the following:
1465           </p>
1466 <pre class="programlisting">channel my_security_channel {
1467     file "my_security_file";
1468     severity info;
1469 };
1470 category security {
1471     my_security_channel;
1472     default_syslog;
1473     default_debug;
1474 };</pre>
1475 <p>
1476             To discard all messages in a category, specify the <span><strong class="command">null</strong></span> channel:
1477           </p>
1478 <pre class="programlisting">category xfer-out { null; };
1479 category notify { null; };
1480 </pre>
1481 <p>
1482             Following are the available categories and brief descriptions
1483             of the types of log information they contain. More
1484             categories may be added in future <acronym class="acronym">BIND</acronym> releases.
1485           </p>
1486 <div class="informaltable"><table border="1">
1487 <colgroup>
1488 <col>
1489 <col>
1490 </colgroup>
1491 <tbody>
1492 <tr>
1493 <td>
1494                     <p><span><strong class="command">default</strong></span></p>
1495                   </td>
1496 <td>
1497                     <p>
1498                       The default category defines the logging
1499                       options for those categories where no specific
1500                       configuration has been
1501                       defined.
1502                     </p>
1503                   </td>
1504 </tr>
1505 <tr>
1506 <td>
1507                     <p><span><strong class="command">general</strong></span></p>
1508                   </td>
1509 <td>
1510                     <p>
1511                       The catch-all. Many things still aren't
1512                       classified into categories, and they all end up here.
1513                     </p>
1514                   </td>
1515 </tr>
1516 <tr>
1517 <td>
1518                     <p><span><strong class="command">database</strong></span></p>
1519                   </td>
1520 <td>
1521                     <p>
1522                       Messages relating to the databases used
1523                       internally by the name server to store zone and cache
1524                       data.
1525                     </p>
1526                   </td>
1527 </tr>
1528 <tr>
1529 <td>
1530                     <p><span><strong class="command">security</strong></span></p>
1531                   </td>
1532 <td>
1533                     <p>
1534                       Approval and denial of requests.
1535                     </p>
1536                   </td>
1537 </tr>
1538 <tr>
1539 <td>
1540                     <p><span><strong class="command">config</strong></span></p>
1541                   </td>
1542 <td>
1543                     <p>
1544                       Configuration file parsing and processing.
1545                     </p>
1546                   </td>
1547 </tr>
1548 <tr>
1549 <td>
1550                     <p><span><strong class="command">resolver</strong></span></p>
1551                   </td>
1552 <td>
1553                     <p>
1554                       DNS resolution, such as the recursive
1555                       lookups performed on behalf of clients by a caching name
1556                       server.
1557                     </p>
1558                   </td>
1559 </tr>
1560 <tr>
1561 <td>
1562                     <p><span><strong class="command">xfer-in</strong></span></p>
1563                   </td>
1564 <td>
1565                     <p>
1566                       Zone transfers the server is receiving.
1567                     </p>
1568                   </td>
1569 </tr>
1570 <tr>
1571 <td>
1572                     <p><span><strong class="command">xfer-out</strong></span></p>
1573                   </td>
1574 <td>
1575                     <p>
1576                       Zone transfers the server is sending.
1577                     </p>
1578                   </td>
1579 </tr>
1580 <tr>
1581 <td>
1582                     <p><span><strong class="command">notify</strong></span></p>
1583                   </td>
1584 <td>
1585                     <p>
1586                       The NOTIFY protocol.
1587                     </p>
1588                   </td>
1589 </tr>
1590 <tr>
1591 <td>
1592                     <p><span><strong class="command">client</strong></span></p>
1593                   </td>
1594 <td>
1595                     <p>
1596                       Processing of client requests.
1597                     </p>
1598                   </td>
1599 </tr>
1600 <tr>
1601 <td>
1602                     <p><span><strong class="command">unmatched</strong></span></p>
1603                   </td>
1604 <td>
1605                     <p>
1606                       Messages that <span><strong class="command">named</strong></span> was unable to determine the
1607                       class of or for which there was no matching <span><strong class="command">view</strong></span>.
1608                       A one line summary is also logged to the <span><strong class="command">client</strong></span> category.
1609                       This category is best sent to a file or stderr, by
1610                       default it is sent to
1611                       the <span><strong class="command">null</strong></span> channel.
1612                     </p>
1613                   </td>
1614 </tr>
1615 <tr>
1616 <td>
1617                     <p><span><strong class="command">network</strong></span></p>
1618                   </td>
1619 <td>
1620                     <p>
1621                       Network operations.
1622                     </p>
1623                   </td>
1624 </tr>
1625 <tr>
1626 <td>
1627                     <p><span><strong class="command">update</strong></span></p>
1628                   </td>
1629 <td>
1630                     <p>
1631                       Dynamic updates.
1632                     </p>
1633                   </td>
1634 </tr>
1635 <tr>
1636 <td>
1637                     <p><span><strong class="command">update-security</strong></span></p>
1638                   </td>
1639 <td>
1640                     <p>
1641                       Approval and denial of update requests.
1642                     </p>
1643                   </td>
1644 </tr>
1645 <tr>
1646 <td>
1647                     <p><span><strong class="command">queries</strong></span></p>
1648                   </td>
1649 <td>
1650                     <p>
1651                       Specify where queries should be logged to.
1652                     </p>
1653                     <p>
1654                       At startup, specifying the category <span><strong class="command">queries</strong></span> will also
1655                       enable query logging unless <span><strong class="command">querylog</strong></span> option has been
1656                       specified.
1657                     </p>
1658
1659                     <p>
1660                       The query log entry reports the client's IP
1661                       address and port number, and the query name,
1662                       class and type.  Next it reports whether the
1663                       Recursion Desired flag was set (+ if set, -
1664                       if not set), if the query was signed (S),
1665                       EDNS was in use (E), if TCP was used (T), if
1666                       DO (DNSSEC Ok) was set (D), or if CD (Checking
1667                       Disabled) was set (C).  After this the
1668                       destination address the query was sent to is
1669                       reported.
1670                     </p>
1671
1672                     <p>
1673                       <code class="computeroutput">client 127.0.0.1#62536 (www.example.com): query: www.example.com IN AAAA +SE</code>
1674                     </p>
1675                     <p>
1676                       <code class="computeroutput">client ::1#62537 (www.example.net): query: www.example.net IN AAAA -SE</code>
1677                     </p>
1678                     <p>
1679                       (The first part of this log message, showing the
1680                       client address/port number and query name, is
1681                       repeated in all subsequent log messages related
1682                       to the same query.)
1683                     </p>
1684                   </td>
1685 </tr>
1686 <tr>
1687 <td>
1688                     <p><span><strong class="command">query-errors</strong></span></p>
1689                   </td>
1690 <td>
1691                     <p>
1692                       Information about queries that resulted in some
1693                       failure.
1694                     </p>
1695                   </td>
1696 </tr>
1697 <tr>
1698 <td>
1699                     <p><span><strong class="command">dispatch</strong></span></p>
1700                   </td>
1701 <td>
1702                     <p>
1703                       Dispatching of incoming packets to the
1704                       server modules where they are to be processed.
1705                     </p>
1706                   </td>
1707 </tr>
1708 <tr>
1709 <td>
1710                     <p><span><strong class="command">dnssec</strong></span></p>
1711                   </td>
1712 <td>
1713                     <p>
1714                       DNSSEC and TSIG protocol processing.
1715                     </p>
1716                   </td>
1717 </tr>
1718 <tr>
1719 <td>
1720                     <p><span><strong class="command">lame-servers</strong></span></p>
1721                   </td>
1722 <td>
1723                     <p>
1724                       Lame servers.  These are misconfigurations
1725                       in remote servers, discovered by BIND 9 when trying to
1726                       query those servers during resolution.
1727                     </p>
1728                   </td>
1729 </tr>
1730 <tr>
1731 <td>
1732                     <p><span><strong class="command">delegation-only</strong></span></p>
1733                   </td>
1734 <td>
1735                     <p>
1736                       Delegation only.  Logs queries that have been
1737                       forced to NXDOMAIN as the result of a
1738                       delegation-only zone or a
1739                       <span><strong class="command">delegation-only</strong></span> in a
1740                       forward, hint or stub zone declaration.
1741                     </p>
1742                   </td>
1743 </tr>
1744 <tr>
1745 <td>
1746                     <p><span><strong class="command">edns-disabled</strong></span></p>
1747                   </td>
1748 <td>
1749                     <p>
1750                       Log queries that have been forced to use plain
1751                       DNS due to timeouts.  This is often due to
1752                       the remote servers not being RFC 1034 compliant
1753                       (not always returning FORMERR or similar to
1754                       EDNS queries and other extensions to the DNS
1755                       when they are not understood).  In other words, this is
1756                       targeted at servers that fail to respond to
1757                       DNS queries that they don't understand.
1758                     </p>
1759                     <p>
1760                       Note: the log message can also be due to
1761                       packet loss.  Before reporting servers for
1762                       non-RFC 1034 compliance they should be re-tested
1763                       to determine the nature of the non-compliance.
1764                       This testing should prevent or reduce the
1765                       number of false-positive reports.
1766                     </p>
1767                     <p>
1768                       Note: eventually <span><strong class="command">named</strong></span> will have to stop
1769                       treating such timeouts as due to RFC 1034 non
1770                       compliance and start treating it as plain
1771                       packet loss.  Falsely classifying packet
1772                       loss as due to RFC 1034 non compliance impacts
1773                       on DNSSEC validation which requires EDNS for
1774                       the DNSSEC records to be returned.
1775                     </p>
1776                   </td>
1777 </tr>
1778 <tr>
1779 <td>
1780                     <p><span><strong class="command">RPZ</strong></span></p>
1781                   </td>
1782 <td>
1783                     <p>
1784                       Information about errors in response policy zone files,
1785                       rewritten responses, and at the highest
1786                       <span><strong class="command">debug</strong></span> levels, mere rewriting
1787                       attempts.
1788                     </p>
1789                   </td>
1790 </tr>
1791 <tr>
1792 <td>
1793                     <p><span><strong class="command">rate-limit</strong></span></p>
1794                   </td>
1795 <td>
1796                     <p>
1797                       (Only available when <acronym class="acronym">BIND</acronym> 9 is
1798                       configured with the <strong class="userinput"><code>--enable-rrl</code></strong>
1799                       option at compile time.)
1800                     </p>
1801                     <p>
1802                       The start, periodic, and final notices of the
1803                       rate limiting of a stream of responses are logged at
1804                       <span><strong class="command">info</strong></span> severity in this category.
1805                       These messages include a hash value of the domain name
1806                       of the response and the name itself,
1807                       except when there is insufficient memory to record
1808                       the name for the final notice
1809                       The final notice is normally delayed until about one
1810                       minute after rate limit stops.
1811                       A lack of memory can hurry the final notice,
1812                       in which case it starts with an asterisk (*).
1813                       Various internal events are logged at debug 1 level
1814                       and higher.
1815                     </p>
1816                     <p>
1817                       Rate limiting of individual requests
1818                       is logged in the <span><strong class="command">query-errors</strong></span> category.
1819                     </p>
1820                   </td>
1821 </tr>
1822 <tr>
1823 <td>
1824                     <p><span><strong class="command">cname</strong></span></p>
1825                   </td>
1826 <td>
1827                     <p>
1828                       Logs nameservers that are skipped due to them being
1829                       a CNAME rather than A / AAAA records.
1830                     </p>
1831                   </td>
1832 </tr>
1833 </tbody>
1834 </table></div>
1835 </div>
1836 <div class="sect3" lang="en">
1837 <div class="titlepage"><div><div><h4 class="title">
1838 <a name="id2576580"></a>The <span><strong class="command">query-errors</strong></span> Category</h4></div></div></div>
1839 <p>
1840             The <span><strong class="command">query-errors</strong></span> category is
1841             specifically intended for debugging purposes: To identify
1842             why and how specific queries result in responses which
1843             indicate an error.
1844             Messages of this category are therefore only logged
1845             with <span><strong class="command">debug</strong></span> levels.
1846           </p>
1847 <p>
1848             At the debug levels of 1 or higher, each response with the
1849             rcode of SERVFAIL is logged as follows:
1850           </p>
1851 <p>
1852             <code class="computeroutput">client 127.0.0.1#61502: query failed (SERVFAIL) for www.example.com/IN/AAAA at query.c:3880</code>
1853           </p>
1854 <p>
1855             This means an error resulting in SERVFAIL was
1856             detected at line 3880 of source file
1857             <code class="filename">query.c</code>.
1858             Log messages of this level will particularly
1859             help identify the cause of SERVFAIL for an
1860             authoritative server.
1861           </p>
1862 <p>
1863             At the debug levels of 2 or higher, detailed context
1864             information of recursive resolutions that resulted in
1865             SERVFAIL is logged.
1866             The log message will look like as follows:
1867           </p>
1868 <p>
1869
1870             </p>
1871 <pre class="programlisting">
1872 fetch completed at resolver.c:2970 for www.example.com/A
1873 in 30.000183: timed out/success [domain:example.com,
1874 referral:2,restart:7,qrysent:8,timeout:5,lame:0,neterr:0,
1875 badresp:1,adberr:0,findfail:0,valfail:0]
1876             </pre>
1877 <p>
1878           </p>
1879 <p>
1880             The first part before the colon shows that a recursive
1881             resolution for AAAA records of www.example.com completed
1882             in 30.000183 seconds and the final result that led to the
1883             SERVFAIL was determined at line 2970 of source file
1884             <code class="filename">resolver.c</code>.
1885           </p>
1886 <p>
1887             The following part shows the detected final result and the
1888             latest result of DNSSEC validation.
1889             The latter is always success when no validation attempt
1890             is made.
1891             In this example, this query resulted in SERVFAIL probably
1892             because all name servers are down or unreachable, leading
1893             to a timeout in 30 seconds.
1894             DNSSEC validation was probably not attempted.
1895           </p>
1896 <p>
1897             The last part enclosed in square brackets shows statistics
1898             information collected for this particular resolution
1899             attempt.
1900             The <code class="varname">domain</code> field shows the deepest zone
1901             that the resolver reached;
1902             it is the zone where the error was finally detected.
1903             The meaning of the other fields is summarized in the
1904             following table.
1905           </p>
1906 <div class="informaltable"><table border="1">
1907 <colgroup>
1908 <col>
1909 <col>
1910 </colgroup>
1911 <tbody>
1912 <tr>
1913 <td>
1914                     <p><code class="varname">referral</code></p>
1915                   </td>
1916 <td>
1917                     <p>
1918                       The number of referrals the resolver received
1919                       throughout the resolution process.
1920                       In the above example this is 2, which are most
1921                       likely com and example.com.
1922                     </p>
1923                   </td>
1924 </tr>
1925 <tr>
1926 <td>
1927                     <p><code class="varname">restart</code></p>
1928                   </td>
1929 <td>
1930                     <p>
1931                       The number of cycles that the resolver tried
1932                       remote servers at the <code class="varname">domain</code>
1933                       zone.
1934                       In each cycle the resolver sends one query
1935                       (possibly resending it, depending on the response)
1936                       to each known name server of
1937                       the <code class="varname">domain</code> zone.
1938                     </p>
1939                   </td>
1940 </tr>
1941 <tr>
1942 <td>
1943                     <p><code class="varname">qrysent</code></p>
1944                   </td>
1945 <td>
1946                     <p>
1947                       The number of queries the resolver sent at the
1948                       <code class="varname">domain</code> zone.
1949                     </p>
1950                   </td>
1951 </tr>
1952 <tr>
1953 <td>
1954                     <p><code class="varname">timeout</code></p>
1955                   </td>
1956 <td>
1957                     <p>
1958                       The number of timeouts since the resolver
1959                       received the last response.
1960                     </p>
1961                   </td>
1962 </tr>
1963 <tr>
1964 <td>
1965                     <p><code class="varname">lame</code></p>
1966                   </td>
1967 <td>
1968                     <p>
1969                       The number of lame servers the resolver detected
1970                       at the <code class="varname">domain</code> zone.
1971                       A server is detected to be lame either by an
1972                       invalid response or as a result of lookup in
1973                       BIND9's address database (ADB), where lame
1974                       servers are cached.
1975                     </p>
1976                   </td>
1977 </tr>
1978 <tr>
1979 <td>
1980                     <p><code class="varname">neterr</code></p>
1981                   </td>
1982 <td>
1983                     <p>
1984                       The number of erroneous results that the
1985                       resolver encountered in sending queries
1986                       at the <code class="varname">domain</code> zone.
1987                       One common case is the remote server is
1988                       unreachable and the resolver receives an ICMP
1989                       unreachable error message.
1990                     </p>
1991                   </td>
1992 </tr>
1993 <tr>
1994 <td>
1995                     <p><code class="varname">badresp</code></p>
1996                   </td>
1997 <td>
1998                     <p>
1999                       The number of unexpected responses (other than
2000                       <code class="varname">lame</code>) to queries sent by the
2001                       resolver at the <code class="varname">domain</code> zone.
2002                     </p>
2003                   </td>
2004 </tr>
2005 <tr>
2006 <td>
2007                     <p><code class="varname">adberr</code></p>
2008                   </td>
2009 <td>
2010                     <p>
2011                       Failures in finding remote server addresses
2012                       of the <code class="varname">domain</code> zone in the ADB.
2013                       One common case of this is that the remote
2014                       server's name does not have any address records.
2015                     </p>
2016                   </td>
2017 </tr>
2018 <tr>
2019 <td>
2020                     <p><code class="varname">findfail</code></p>
2021                   </td>
2022 <td>
2023                     <p>
2024                       Failures of resolving remote server addresses.
2025                       This is a total number of failures throughout
2026                       the resolution process.
2027                     </p>
2028                   </td>
2029 </tr>
2030 <tr>
2031 <td>
2032                     <p><code class="varname">valfail</code></p>
2033                   </td>
2034 <td>
2035                     <p>
2036                       Failures of DNSSEC validation.
2037                       Validation failures are counted throughout
2038                       the resolution process (not limited to
2039                       the <code class="varname">domain</code> zone), but should
2040                       only happen in <code class="varname">domain</code>.
2041                     </p>
2042                   </td>
2043 </tr>
2044 </tbody>
2045 </table></div>
2046 <p>
2047             At the debug levels of 3 or higher, the same messages
2048             as those at the debug 1 level are logged for other errors
2049             than SERVFAIL.
2050             Note that negative responses such as NXDOMAIN are not
2051             regarded as errors here.
2052           </p>
2053 <p>
2054             At the debug levels of 4 or higher, the same messages
2055             as those at the debug 2 level are logged for other errors
2056             than SERVFAIL.
2057             Unlike the above case of level 3, messages are logged for
2058             negative responses.
2059             This is because any unexpected results can be difficult to
2060             debug in the recursion case.
2061           </p>
2062 </div>
2063 </div>
2064 <div class="sect2" lang="en">
2065 <div class="titlepage"><div><div><h3 class="title">
2066 <a name="id2577168"></a><span><strong class="command">lwres</strong></span> Statement Grammar</h3></div></div></div>
2067 <p>
2068            This is the grammar of the <span><strong class="command">lwres</strong></span>
2069           statement in the <code class="filename">named.conf</code> file:
2070         </p>
2071 <pre class="programlisting"><span><strong class="command">lwres</strong></span> {
2072     [<span class="optional"> listen-on { <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ;
2073                 [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; ... </span>] }; </span>]
2074     [<span class="optional"> view <em class="replaceable"><code>view_name</code></em>; </span>]
2075     [<span class="optional"> search { <em class="replaceable"><code>domain_name</code></em> ; [<span class="optional"> <em class="replaceable"><code>domain_name</code></em> ; ... </span>] }; </span>]
2076     [<span class="optional"> ndots <em class="replaceable"><code>number</code></em>; </span>]
2077 };
2078 </pre>
2079 </div>
2080 <div class="sect2" lang="en">
2081 <div class="titlepage"><div><div><h3 class="title">
2082 <a name="id2577241"></a><span><strong class="command">lwres</strong></span> Statement Definition and Usage</h3></div></div></div>
2083 <p>
2084           The <span><strong class="command">lwres</strong></span> statement configures the
2085           name
2086           server to also act as a lightweight resolver server. (See
2087           <a href="Bv9ARM.ch05.html#lwresd" title="Running a Resolver Daemon">the section called &#8220;Running a Resolver Daemon&#8221;</a>.)  There may be multiple
2088           <span><strong class="command">lwres</strong></span> statements configuring
2089           lightweight resolver servers with different properties.
2090         </p>
2091 <p>
2092           The <span><strong class="command">listen-on</strong></span> statement specifies a
2093           list of
2094           IPv4 addresses (and ports) that this instance of a lightweight
2095           resolver daemon
2096           should accept requests on.  If no port is specified, port 921 is
2097           used.
2098           If this statement is omitted, requests will be accepted on
2099           127.0.0.1,
2100           port 921.
2101         </p>
2102 <p>
2103           The <span><strong class="command">view</strong></span> statement binds this
2104           instance of a
2105           lightweight resolver daemon to a view in the DNS namespace, so that
2106           the
2107           response will be constructed in the same manner as a normal DNS
2108           query
2109           matching this view.  If this statement is omitted, the default view
2110           is
2111           used, and if there is no default view, an error is triggered.
2112         </p>
2113 <p>
2114           The <span><strong class="command">search</strong></span> statement is equivalent to
2115           the
2116           <span><strong class="command">search</strong></span> statement in
2117           <code class="filename">/etc/resolv.conf</code>.  It provides a
2118           list of domains
2119           which are appended to relative names in queries.
2120         </p>
2121 <p>
2122           The <span><strong class="command">ndots</strong></span> statement is equivalent to
2123           the
2124           <span><strong class="command">ndots</strong></span> statement in
2125           <code class="filename">/etc/resolv.conf</code>.  It indicates the
2126           minimum
2127           number of dots in a relative domain name that should result in an
2128           exact match lookup before search path elements are appended.
2129         </p>
2130 </div>
2131 <div class="sect2" lang="en">
2132 <div class="titlepage"><div><div><h3 class="title">
2133 <a name="id2577305"></a><span><strong class="command">masters</strong></span> Statement Grammar</h3></div></div></div>
2134 <pre class="programlisting">
2135 <span><strong class="command">masters</strong></span> <em class="replaceable"><code>name</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] { ( <em class="replaceable"><code>masters_list</code></em> | 
2136       <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] [<span class="optional">key <em class="replaceable"><code>key</code></em></span>] ) ; [<span class="optional">...</span>] };
2137 </pre>
2138 </div>
2139 <div class="sect2" lang="en">
2140 <div class="titlepage"><div><div><h3 class="title">
2141 <a name="id2577417"></a><span><strong class="command">masters</strong></span> Statement Definition and
2142           Usage</h3></div></div></div>
2143 <p><span><strong class="command">masters</strong></span>
2144           lists allow for a common set of masters to be easily used by
2145           multiple stub and slave zones in their <span><strong class="command">masters</strong></span>
2146           or <span><strong class="command">also-notify</strong></span> lists.
2147         </p>
2148 </div>
2149 <div class="sect2" lang="en">
2150 <div class="titlepage"><div><div><h3 class="title">
2151 <a name="id2577438"></a><span><strong class="command">options</strong></span> Statement Grammar</h3></div></div></div>
2152 <p>
2153           This is the grammar of the <span><strong class="command">options</strong></span>
2154           statement in the <code class="filename">named.conf</code> file:
2155         </p>
2156 <pre class="programlisting"><span><strong class="command">options</strong></span> {
2157     [<span class="optional"> attach-cache <em class="replaceable"><code>cache_name</code></em>; </span>]
2158     [<span class="optional"> version <em class="replaceable"><code>version_string</code></em>; </span>]
2159     [<span class="optional"> hostname <em class="replaceable"><code>hostname_string</code></em>; </span>]
2160     [<span class="optional"> server-id <em class="replaceable"><code>server_id_string</code></em>; </span>]
2161     [<span class="optional"> directory <em class="replaceable"><code>path_name</code></em>; </span>]
2162     [<span class="optional"> key-directory <em class="replaceable"><code>path_name</code></em>; </span>]
2163     [<span class="optional"> managed-keys-directory <em class="replaceable"><code>path_name</code></em>; </span>]
2164     [<span class="optional"> named-xfer <em class="replaceable"><code>path_name</code></em>; </span>]
2165     [<span class="optional"> tkey-gssapi-keytab <em class="replaceable"><code>path_name</code></em>; </span>]
2166     [<span class="optional"> tkey-gssapi-credential <em class="replaceable"><code>principal</code></em>; </span>]
2167     [<span class="optional"> tkey-domain <em class="replaceable"><code>domainname</code></em>; </span>]
2168     [<span class="optional"> tkey-dhkey <em class="replaceable"><code>key_name</code></em> <em class="replaceable"><code>key_tag</code></em>; </span>]
2169     [<span class="optional"> cache-file <em class="replaceable"><code>path_name</code></em>; </span>]
2170     [<span class="optional"> dump-file <em class="replaceable"><code>path_name</code></em>; </span>]
2171     [<span class="optional"> bindkeys-file <em class="replaceable"><code>path_name</code></em>; </span>]
2172     [<span class="optional"> secroots-file <em class="replaceable"><code>path_name</code></em>; </span>]
2173     [<span class="optional"> session-keyfile <em class="replaceable"><code>path_name</code></em>; </span>]
2174     [<span class="optional"> session-keyname <em class="replaceable"><code>key_name</code></em>; </span>]
2175     [<span class="optional"> session-keyalg <em class="replaceable"><code>algorithm_id</code></em>; </span>]
2176     [<span class="optional"> memstatistics <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2177     [<span class="optional"> memstatistics-file <em class="replaceable"><code>path_name</code></em>; </span>]
2178     [<span class="optional"> pid-file <em class="replaceable"><code>path_name</code></em>; </span>]
2179     [<span class="optional"> recursing-file <em class="replaceable"><code>path_name</code></em>; </span>]
2180     [<span class="optional"> statistics-file <em class="replaceable"><code>path_name</code></em>; </span>]
2181     [<span class="optional"> zone-statistics <em class="replaceable"><code>full</code></em> | <em class="replaceable"><code>terse</code></em> | <em class="replaceable"><code>none</code></em>; </span>]
2182     [<span class="optional"> auth-nxdomain <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2183     [<span class="optional"> deallocate-on-exit <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2184     [<span class="optional"> dialup <em class="replaceable"><code>dialup_option</code></em>; </span>]
2185     [<span class="optional"> fake-iquery <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2186     [<span class="optional"> fetch-glue <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2187     [<span class="optional"> flush-zones-on-shutdown <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2188     [<span class="optional"> has-old-clients <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2189     [<span class="optional"> host-statistics <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2190     [<span class="optional"> host-statistics-max <em class="replaceable"><code>number</code></em>; </span>]
2191     [<span class="optional"> minimal-responses <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2192     [<span class="optional"> multiple-cnames <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2193     [<span class="optional"> notify <em class="replaceable"><code>yes_or_no</code></em> | <em class="replaceable"><code>explicit</code></em> | <em class="replaceable"><code>master-only</code></em>; </span>]
2194     [<span class="optional"> recursion <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2195     [<span class="optional"> request-nsid <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2196     [<span class="optional"> rfc2308-type1 <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2197     [<span class="optional"> use-id-pool <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2198     [<span class="optional"> maintain-ixfr-base <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2199     [<span class="optional"> ixfr-from-differences (<em class="replaceable"><code>yes_or_no</code></em> | <code class="constant">master</code> | <code class="constant">slave</code>); </span>]
2200     [<span class="optional"> dnssec-enable <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2201     [<span class="optional"> dnssec-validation (<em class="replaceable"><code>yes_or_no</code></em> | <code class="constant">auto</code>); </span>]
2202     [<span class="optional"> dnssec-lookaside ( <em class="replaceable"><code>auto</code></em> |
2203                         <em class="replaceable"><code>no</code></em> |
2204                         <em class="replaceable"><code>domain</code></em> trust-anchor <em class="replaceable"><code>domain</code></em> ); </span>]
2205     [<span class="optional"> dnssec-must-be-secure <em class="replaceable"><code>domain yes_or_no</code></em>; </span>]
2206     [<span class="optional"> dnssec-accept-expired <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2207     [<span class="optional"> forward ( <em class="replaceable"><code>only</code></em> | <em class="replaceable"><code>first</code></em> ); </span>]
2208     [<span class="optional"> forwarders { [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; ... </span>] }; </span>]
2209     [<span class="optional"> dual-stack-servers [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] {
2210         ( <em class="replaceable"><code>domain_name</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] |
2211           <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ) ; 
2212         ... }; </span>]
2213     [<span class="optional"> check-names ( <em class="replaceable"><code>master</code></em> | <em class="replaceable"><code>slave</code></em> | <em class="replaceable"><code>response</code></em> )
2214         ( <em class="replaceable"><code>warn</code></em> | <em class="replaceable"><code>fail</code></em> | <em class="replaceable"><code>ignore</code></em> ); </span>]
2215     [<span class="optional"> check-dup-records ( <em class="replaceable"><code>warn</code></em> | <em class="replaceable"><code>fail</code></em> | <em class="replaceable"><code>ignore</code></em> ); </span>]
2216     [<span class="optional"> check-mx ( <em class="replaceable"><code>warn</code></em> | <em class="replaceable"><code>fail</code></em> | <em class="replaceable"><code>ignore</code></em> ); </span>]
2217     [<span class="optional"> check-wildcard <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2218     [<span class="optional"> check-integrity <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2219     [<span class="optional"> check-mx-cname ( <em class="replaceable"><code>warn</code></em> | <em class="replaceable"><code>fail</code></em> | <em class="replaceable"><code>ignore</code></em> ); </span>]
2220     [<span class="optional"> check-srv-cname ( <em class="replaceable"><code>warn</code></em> | <em class="replaceable"><code>fail</code></em> | <em class="replaceable"><code>ignore</code></em> ); </span>]
2221     [<span class="optional"> check-sibling <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2222     [<span class="optional"> check-spf ( <em class="replaceable"><code>warn</code></em> | <em class="replaceable"><code>ignore</code></em> ); </span>]
2223     [<span class="optional"> allow-new-zones { <em class="replaceable"><code>yes_or_no</code></em> }; </span>]
2224     [<span class="optional"> allow-notify { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2225     [<span class="optional"> allow-query { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2226     [<span class="optional"> allow-query-on { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2227     [<span class="optional"> allow-query-cache { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2228     [<span class="optional"> allow-query-cache-on { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2229     [<span class="optional"> allow-transfer { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2230     [<span class="optional"> allow-recursion { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2231     [<span class="optional"> allow-recursion-on { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2232     [<span class="optional"> allow-update { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2233     [<span class="optional"> allow-update-forwarding { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2234     [<span class="optional"> update-check-ksk <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2235     [<span class="optional"> dnssec-update-mode ( <em class="replaceable"><code>maintain</code></em> | <em class="replaceable"><code>no-resign</code></em> ); </span>]
2236     [<span class="optional"> dnssec-dnskey-kskonly <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2237     [<span class="optional"> dnssec-loadkeys-interval <em class="replaceable"><code>number</code></em>; </span>]
2238     [<span class="optional"> dnssec-secure-to-insecure <em class="replaceable"><code>yes_or_no</code></em> ;</span>]
2239     [<span class="optional"> try-tcp-refresh <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2240     [<span class="optional"> allow-v6-synthesis { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2241     [<span class="optional"> blackhole { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2242     [<span class="optional"> no-case-compress { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2243     [<span class="optional"> use-v4-udp-ports { <em class="replaceable"><code>port_list</code></em> }; </span>]
2244     [<span class="optional"> avoid-v4-udp-ports { <em class="replaceable"><code>port_list</code></em> }; </span>]
2245     [<span class="optional"> use-v6-udp-ports { <em class="replaceable"><code>port_list</code></em> }; </span>]
2246     [<span class="optional"> avoid-v6-udp-ports { <em class="replaceable"><code>port_list</code></em> }; </span>]
2247     [<span class="optional"> listen-on [<span class="optional"> port <em class="replaceable"><code>ip_port</code></em> </span>] { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2248     [<span class="optional"> listen-on-v6 [<span class="optional"> port <em class="replaceable"><code>ip_port</code></em> </span>] { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2249     [<span class="optional"> query-source ( ( <em class="replaceable"><code>ip4_addr</code></em> | <em class="replaceable"><code>*</code></em> )
2250         [<span class="optional"> port ( <em class="replaceable"><code>ip_port</code></em> | <em class="replaceable"><code>*</code></em> ) </span>] |
2251         [<span class="optional"> address ( <em class="replaceable"><code>ip4_addr</code></em> | <em class="replaceable"><code>*</code></em> ) </span>]
2252         [<span class="optional"> port ( <em class="replaceable"><code>ip_port</code></em> | <em class="replaceable"><code>*</code></em> ) </span>] ) ; </span>]
2253     [<span class="optional"> query-source-v6 ( ( <em class="replaceable"><code>ip6_addr</code></em> | <em class="replaceable"><code>*</code></em> )
2254         [<span class="optional"> port ( <em class="replaceable"><code>ip_port</code></em> | <em class="replaceable"><code>*</code></em> ) </span>] | 
2255         [<span class="optional"> address ( <em class="replaceable"><code>ip6_addr</code></em> | <em class="replaceable"><code>*</code></em> ) </span>] 
2256         [<span class="optional"> port ( <em class="replaceable"><code>ip_port</code></em> | <em class="replaceable"><code>*</code></em> ) </span>] ) ; </span>]
2257     [<span class="optional"> use-queryport-pool <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2258     [<span class="optional"> queryport-pool-ports <em class="replaceable"><code>number</code></em>; </span>]
2259     [<span class="optional"> queryport-pool-updateinterval <em class="replaceable"><code>number</code></em>; </span>]
2260     [<span class="optional"> max-transfer-time-in <em class="replaceable"><code>number</code></em>; </span>]
2261     [<span class="optional"> max-transfer-time-out <em class="replaceable"><code>number</code></em>; </span>]
2262     [<span class="optional"> max-transfer-idle-in <em class="replaceable"><code>number</code></em>; </span>]
2263     [<span class="optional"> max-transfer-idle-out <em class="replaceable"><code>number</code></em>; </span>]
2264     [<span class="optional"> tcp-clients <em class="replaceable"><code>number</code></em>; </span>]
2265     [<span class="optional"> reserved-sockets <em class="replaceable"><code>number</code></em>; </span>]
2266     [<span class="optional"> recursive-clients <em class="replaceable"><code>number</code></em>; </span>]
2267     [<span class="optional"> serial-query-rate <em class="replaceable"><code>number</code></em>; </span>]
2268     [<span class="optional"> serial-queries <em class="replaceable"><code>number</code></em>; </span>]
2269     [<span class="optional"> tcp-listen-queue <em class="replaceable"><code>number</code></em>; </span>]
2270     [<span class="optional"> transfer-format <em class="replaceable"><code>( one-answer | many-answers )</code></em>; </span>]
2271     [<span class="optional"> transfers-in  <em class="replaceable"><code>number</code></em>; </span>]
2272     [<span class="optional"> transfers-out <em class="replaceable"><code>number</code></em>; </span>]
2273     [<span class="optional"> transfers-per-ns <em class="replaceable"><code>number</code></em>; </span>]
2274     [<span class="optional"> transfer-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
2275     [<span class="optional"> transfer-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
2276     [<span class="optional"> alt-transfer-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
2277     [<span class="optional"> alt-transfer-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>)
2278                              [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
2279     [<span class="optional"> use-alt-transfer-source <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2280     [<span class="optional"> notify-delay <em class="replaceable"><code>seconds</code></em> ; </span>]
2281     [<span class="optional"> notify-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
2282     [<span class="optional"> notify-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
2283     [<span class="optional"> notify-to-soa <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2284     [<span class="optional"> also-notify { <em class="replaceable"><code>ip_addr</code></em>
2285                     [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] [<span class="optional">key <em class="replaceable"><code>keyname</code></em></span>] ;
2286                     [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] [<span class="optional">key <em class="replaceable"><code>keyname</code></em></span>] ; ... </span>] }; </span>]
2287     [<span class="optional"> max-ixfr-log-size <em class="replaceable"><code>number</code></em>; </span>]
2288     [<span class="optional"> max-journal-size <em class="replaceable"><code>size_spec</code></em>; </span>]
2289     [<span class="optional"> coresize <em class="replaceable"><code>size_spec</code></em> ; </span>]
2290     [<span class="optional"> datasize <em class="replaceable"><code>size_spec</code></em> ; </span>]
2291     [<span class="optional"> files <em class="replaceable"><code>size_spec</code></em> ; </span>]
2292     [<span class="optional"> stacksize <em class="replaceable"><code>size_spec</code></em> ; </span>]
2293     [<span class="optional"> cleaning-interval <em class="replaceable"><code>number</code></em>; </span>]
2294     [<span class="optional"> heartbeat-interval <em class="replaceable"><code>number</code></em>; </span>]
2295     [<span class="optional"> interface-interval <em class="replaceable"><code>number</code></em>; </span>]
2296     [<span class="optional"> statistics-interval <em class="replaceable"><code>number</code></em>; </span>]
2297     [<span class="optional"> topology { <em class="replaceable"><code>address_match_list</code></em> }</span>];
2298     [<span class="optional"> sortlist { <em class="replaceable"><code>address_match_list</code></em> }</span>];
2299     [<span class="optional"> rrset-order { <em class="replaceable"><code>order_spec</code></em> ; [<span class="optional"> <em class="replaceable"><code>order_spec</code></em> ; ... </span>] </span>] };
2300     [<span class="optional"> lame-ttl <em class="replaceable"><code>number</code></em>; </span>]
2301     [<span class="optional"> max-ncache-ttl <em class="replaceable"><code>number</code></em>; </span>]
2302     [<span class="optional"> max-cache-ttl <em class="replaceable"><code>number</code></em>; </span>]
2303     [<span class="optional"> sig-validity-interval <em class="replaceable"><code>number</code></em> [<span class="optional"><em class="replaceable"><code>number</code></em></span>] ; </span>]
2304     [<span class="optional"> sig-signing-nodes <em class="replaceable"><code>number</code></em> ; </span>]
2305     [<span class="optional"> sig-signing-signatures <em class="replaceable"><code>number</code></em> ; </span>]
2306     [<span class="optional"> sig-signing-type <em class="replaceable"><code>number</code></em> ; </span>]
2307     [<span class="optional"> min-roots <em class="replaceable"><code>number</code></em>; </span>]
2308     [<span class="optional"> use-ixfr <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2309     [<span class="optional"> provide-ixfr <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2310     [<span class="optional"> request-ixfr <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2311     [<span class="optional"> treat-cr-as-space <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2312     [<span class="optional"> min-refresh-time <em class="replaceable"><code>number</code></em> ; </span>]
2313     [<span class="optional"> max-refresh-time <em class="replaceable"><code>number</code></em> ; </span>]
2314     [<span class="optional"> min-retry-time <em class="replaceable"><code>number</code></em> ; </span>]
2315     [<span class="optional"> max-retry-time <em class="replaceable"><code>number</code></em> ; </span>]
2316     [<span class="optional"> port <em class="replaceable"><code>ip_port</code></em>; </span>]
2317     [<span class="optional"> additional-from-auth <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2318     [<span class="optional"> additional-from-cache <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2319     [<span class="optional"> random-device <em class="replaceable"><code>path_name</code></em> ; </span>]
2320     [<span class="optional"> max-cache-size <em class="replaceable"><code>size_spec</code></em> ; </span>]
2321     [<span class="optional"> match-mapped-addresses <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2322     [<span class="optional"> filter-aaaa-on-v4 ( <em class="replaceable"><code>yes_or_no</code></em> | <em class="replaceable"><code>break-dnssec</code></em> ); </span>]
2323     [<span class="optional"> filter-aaaa { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2324     [<span class="optional"> dns64 <em class="replaceable"><code>ipv6-prefix</code></em> {
2325         [<span class="optional"> clients { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2326         [<span class="optional"> mapped { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2327         [<span class="optional"> exclude { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
2328         [<span class="optional"> suffix IPv6-address; </span>]
2329         [<span class="optional"> recursive-only <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2330         [<span class="optional"> break-dnssec <em class="replaceable"><code>yes_or_no</code></em>; </span>]
2331     }; </span>];
2332     [<span class="optional"> dns64-server <em class="replaceable"><code>name</code></em> </span>]
2333     [<span class="optional"> dns64-contact <em class="replaceable"><code>name</code></em> </span>]
2334     [<span class="optional"> preferred-glue ( <em class="replaceable"><code>A</code></em> | <em class="replaceable"><code>AAAA</code></em> | <em class="replaceable"><code>NONE</code></em> ); </span>]
2335     [<span class="optional"> edns-udp-size <em class="replaceable"><code>number</code></em>; </span>]
2336     [<span class="optional"> max-udp-size <em class="replaceable"><code>number</code></em>; </span>]
2337     [<span class="optional"> max-rsa-exponent-size <em class="replaceable"><code>number</code></em>; </span>]
2338     [<span class="optional"> root-delegation-only [<span class="optional"> exclude { <em class="replaceable"><code>namelist</code></em> } </span>] ; </span>]
2339     [<span class="optional"> querylog <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2340     [<span class="optional"> disable-algorithms <em class="replaceable"><code>domain</code></em> { <em class="replaceable"><code>algorithm</code></em>;
2341                                 [<span class="optional"> <em class="replaceable"><code>algorithm</code></em>; </span>] }; </span>]
2342     [<span class="optional"> acache-enable <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2343     [<span class="optional"> acache-cleaning-interval <em class="replaceable"><code>number</code></em>; </span>]
2344     [<span class="optional"> max-acache-size <em class="replaceable"><code>size_spec</code></em> ; </span>]
2345     [<span class="optional"> clients-per-query <em class="replaceable"><code>number</code></em> ; </span>]
2346     [<span class="optional"> max-clients-per-query <em class="replaceable"><code>number</code></em> ; </span>]
2347     [<span class="optional"> max-recursion-depth <em class="replaceable"><code>number</code></em> ; </span>]
2348     [<span class="optional"> max-recursion-queries <em class="replaceable"><code>number</code></em> ; </span>]
2349     [<span class="optional"> masterfile-format (<code class="constant">text</code>|<code class="constant">raw</code>) ; </span>]
2350     [<span class="optional"> empty-server <em class="replaceable"><code>name</code></em> ; </span>]
2351     [<span class="optional"> empty-contact <em class="replaceable"><code>name</code></em> ; </span>]
2352     [<span class="optional"> empty-zones-enable <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2353     [<span class="optional"> disable-empty-zone <em class="replaceable"><code>zone_name</code></em> ; </span>]
2354     [<span class="optional"> zero-no-soa-ttl <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2355     [<span class="optional"> zero-no-soa-ttl-cache <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2356     [<span class="optional"> resolver-query-timeout <em class="replaceable"><code>number</code></em> ; </span>]
2357     [<span class="optional"> deny-answer-addresses { <em class="replaceable"><code>address_match_list</code></em> } [<span class="optional"> except-from { <em class="replaceable"><code>namelist</code></em> } </span>];</span>]
2358     [<span class="optional"> deny-answer-aliases { <em class="replaceable"><code>namelist</code></em> } [<span class="optional"> except-from { <em class="replaceable"><code>namelist</code></em> } </span>];</span>]
2359     [<span class="optional"> rate-limit {
2360         [<span class="optional"> responses-per-second <em class="replaceable"><code>number</code></em> ; </span>]
2361         [<span class="optional"> referrals-per-second <em class="replaceable"><code>number</code></em> ; </span>]
2362         [<span class="optional"> nodata-per-second <em class="replaceable"><code>number</code></em> ; </span>]
2363         [<span class="optional"> nxdomains-per-second <em class="replaceable"><code>number</code></em> ; </span>]
2364         [<span class="optional"> errors-per-second <em class="replaceable"><code>number</code></em> ; </span>]
2365         [<span class="optional"> all-per-second <em class="replaceable"><code>number</code></em> ; </span>]
2366         [<span class="optional"> window <em class="replaceable"><code>number</code></em> ; </span>]
2367         [<span class="optional"> log-only <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
2368         [<span class="optional"> qps-scale <em class="replaceable"><code>number</code></em> ; </span>]
2369         [<span class="optional"> ipv4-prefix-length <em class="replaceable"><code>number</code></em> ; </span>]
2370         [<span class="optional"> ipv6-prefix-length <em class="replaceable"><code>number</code></em> ; </span>]
2371         [<span class="optional"> slip <em class="replaceable"><code>number</code></em> ; </span>]
2372         [<span class="optional"> exempt-clients  { <em class="replaceable"><code>address_match_list</code></em> } ; </span>]
2373         [<span class="optional"> max-table-size <em class="replaceable"><code>number</code></em> ; </span>]
2374         [<span class="optional"> min-table-size <em class="replaceable"><code>number</code></em> ; </span>]
2375     } ; </span>]
2376     [<span class="optional"> response-policy {
2377         zone <em class="replaceable"><code>zone_name</code></em>
2378         [<span class="optional"> policy <em class="replaceable"><code>(given | disabled | passthru |
2379                   nxdomain | nodata | cname domain</code></em>) </span>]
2380         [<span class="optional"> recursive-only <em class="replaceable"><code>yes_or_no</code></em> </span>]
2381         [<span class="optional"> max-policy-ttl <em class="replaceable"><code>number</code></em> </span>]
2382         [<span class="optional"> break-dnssec <em class="replaceable"><code>yes_or_no</code></em> </span>]
2383         [<span class="optional"> min-ns-dots <em class="replaceable"><code>number</code></em> </span>]
2384         ; [<span class="optional">...</span>]
2385     } ; </span>]
2386 };
2387 </pre>
2388 </div>
2389 <div class="sect2" lang="en">
2390 <div class="titlepage"><div><div><h3 class="title">
2391 <a name="options"></a><span><strong class="command">options</strong></span> Statement Definition and
2392           Usage</h3></div></div></div>
2393 <p>
2394           The <span><strong class="command">options</strong></span> statement sets up global
2395           options
2396           to be used by <acronym class="acronym">BIND</acronym>. This statement
2397           may appear only
2398           once in a configuration file. If there is no <span><strong class="command">options</strong></span>
2399           statement, an options block with each option set to its default will
2400           be used.
2401         </p>
2402 <div class="variablelist"><dl>
2403 <dt><span class="term"><span><strong class="command">attach-cache</strong></span></span></dt>
2404 <dd>
2405 <p>
2406                   Allows multiple views to share a single cache
2407                   database.
2408                   Each view has its own cache database by default, but
2409                   if multiple views have the same operational policy
2410                   for name resolution and caching, those views can
2411                   share a single cache to save memory and possibly
2412                   improve resolution efficiency by using this option.
2413                 </p>
2414 <p>
2415                   The <span><strong class="command">attach-cache</strong></span> option
2416                   may also be specified in <span><strong class="command">view</strong></span>
2417                   statements, in which case it overrides the
2418                   global <span><strong class="command">attach-cache</strong></span> option.
2419                 </p>
2420 <p>
2421                   The <em class="replaceable"><code>cache_name</code></em> specifies
2422                   the cache to be shared.
2423                   When the <span><strong class="command">named</strong></span> server configures
2424                   views which are supposed to share a cache, it
2425                   creates a cache with the specified name for the
2426                   first view of these sharing views.
2427                   The rest of the views will simply refer to the
2428                   already created cache.
2429                 </p>
2430 <p>
2431                   One common configuration to share a cache would be to
2432                   allow all views to share a single cache.
2433                   This can be done by specifying
2434                   the <span><strong class="command">attach-cache</strong></span> as a global
2435                   option with an arbitrary name.
2436                 </p>
2437 <p>
2438                   Another possible operation is to allow a subset of
2439                   all views to share a cache while the others to
2440                   retain their own caches.
2441                   For example, if there are three views A, B, and C,
2442                   and only A and B should share a cache, specify the
2443                   <span><strong class="command">attach-cache</strong></span> option as a view A (or
2444                   B)'s option, referring to the other view name:
2445                 </p>
2446 <pre class="programlisting">
2447   view "A" {
2448     // this view has its own cache
2449     ...
2450   };
2451   view "B" {
2452     // this view refers to A's cache
2453     attach-cache "A";
2454   };
2455   view "C" {
2456     // this view has its own cache
2457     ...
2458   };
2459 </pre>
2460 <p>
2461                   Views that share a cache must have the same policy
2462                   on configurable parameters that may affect caching.
2463                   The current implementation requires the following
2464                   configurable options be consistent among these
2465                   views:
2466                   <span><strong class="command">check-names</strong></span>,
2467                   <span><strong class="command">cleaning-interval</strong></span>,
2468                   <span><strong class="command">dnssec-accept-expired</strong></span>,
2469                   <span><strong class="command">dnssec-validation</strong></span>,
2470                   <span><strong class="command">max-cache-ttl</strong></span>,
2471                   <span><strong class="command">max-ncache-ttl</strong></span>,
2472                   <span><strong class="command">max-cache-size</strong></span>, and
2473                   <span><strong class="command">zero-no-soa-ttl</strong></span>.
2474                 </p>
2475 <p>
2476                   Note that there may be other parameters that may
2477                   cause confusion if they are inconsistent for
2478                   different views that share a single cache.
2479                   For example, if these views define different sets of
2480                   forwarders that can return different answers for the
2481                   same question, sharing the answer does not make
2482                   sense or could even be harmful.
2483                   It is administrator's responsibility to ensure
2484                   configuration differences in different views do
2485                   not cause disruption with a shared cache.
2486                 </p>
2487 </dd>
2488 <dt><span class="term"><span><strong class="command">directory</strong></span></span></dt>
2489 <dd><p>
2490                 The working directory of the server.
2491                 Any non-absolute pathnames in the configuration file will be
2492                 taken
2493                 as relative to this directory. The default location for most
2494                 server
2495                 output files (e.g. <code class="filename">named.run</code>)
2496                 is this directory.
2497                 If a directory is not specified, the working directory
2498                 defaults to `<code class="filename">.</code>', the directory from
2499                 which the server
2500                 was started. The directory specified should be an absolute
2501                 path.
2502               </p></dd>
2503 <dt><span class="term"><span><strong class="command">key-directory</strong></span></span></dt>
2504 <dd><p>
2505                 When performing dynamic update of secure zones, the
2506                 directory where the public and private DNSSEC key files
2507                 should be found, if different than the current working
2508                 directory.  (Note that this option has no effect on the
2509                 paths for files containing non-DNSSEC keys such as
2510                 <code class="filename">bind.keys</code>,
2511                 <code class="filename">rndc.key</code> or
2512                 <code class="filename">session.key</code>.)
2513               </p></dd>
2514 <dt><span class="term"><span><strong class="command">managed-keys-directory</strong></span></span></dt>
2515 <dd>
2516 <p>
2517                 Specifies the directory in which to store the files that
2518                 track managed DNSSEC keys.  By default, this is the working
2519                 directory.
2520               </p>
2521 <p>
2522                 If <span><strong class="command">named</strong></span> is not configured to use views,
2523                 then managed keys for the server will be tracked in a single
2524                 file called <code class="filename">managed-keys.bind</code>.
2525                 Otherwise, managed keys will be tracked in separate files,
2526                 one file per view; each file name will be the SHA256 hash
2527                 of the view name, followed by the extension
2528                 <code class="filename">.mkeys</code>.
2529               </p>
2530 </dd>
2531 <dt><span class="term"><span><strong class="command">named-xfer</strong></span></span></dt>
2532 <dd><p>
2533                 <span class="emphasis"><em>This option is obsolete.</em></span> It
2534                 was used in <acronym class="acronym">BIND</acronym> 8 to specify
2535                 the pathname to the <span><strong class="command">named-xfer</strong></span>
2536                 program.  In <acronym class="acronym">BIND</acronym> 9, no separate
2537                 <span><strong class="command">named-xfer</strong></span> program is needed;
2538                 its functionality is built into the name server.
2539               </p></dd>
2540 <dt><span class="term"><span><strong class="command">tkey-gssapi-keytab</strong></span></span></dt>
2541 <dd><p>
2542                 The KRB5 keytab file to use for GSS-TSIG updates. If
2543                 this option is set and tkey-gssapi-credential is not
2544                 set, then updates will be allowed with any key
2545                 matching a principal in the specified keytab.
2546               </p></dd>
2547 <dt><span class="term"><span><strong class="command">tkey-gssapi-credential</strong></span></span></dt>
2548 <dd><p>
2549                 The security credential with which the server should
2550                 authenticate keys requested by the GSS-TSIG protocol.
2551                 Currently only Kerberos 5 authentication is available
2552                 and the credential is a Kerberos principal which the
2553                 server can acquire through the default system key
2554                 file, normally <code class="filename">/etc/krb5.keytab</code>.
2555                 The location keytab file can be overridden using the
2556                 tkey-gssapi-keytab option. Normally this principal is
2557                 of the form "<strong class="userinput"><code>DNS/</code></strong><code class="varname">server.domain</code>".
2558                 To use GSS-TSIG, <span><strong class="command">tkey-domain</strong></span> must
2559                 also be set if a specific keytab is not set with
2560                 tkey-gssapi-keytab.
2561               </p></dd>
2562 <dt><span class="term"><span><strong class="command">tkey-domain</strong></span></span></dt>
2563 <dd><p>
2564                 The domain appended to the names of all shared keys
2565                 generated with <span><strong class="command">TKEY</strong></span>.  When a
2566                 client requests a <span><strong class="command">TKEY</strong></span> exchange,
2567                 it may or may not specify the desired name for the
2568                 key. If present, the name of the shared key will
2569                 be <code class="varname">client specified part</code> +
2570                 <code class="varname">tkey-domain</code>.  Otherwise, the
2571                 name of the shared key will be <code class="varname">random hex
2572                 digits</code> + <code class="varname">tkey-domain</code>.
2573                 In most cases, the <span><strong class="command">domainname</strong></span>
2574                 should be the server's domain name, or an otherwise
2575                 non-existent subdomain like
2576                 "_tkey.<code class="varname">domainname</code>".  If you are
2577                 using GSS-TSIG, this variable must be defined, unless
2578                 you specify a specific keytab using tkey-gssapi-keytab.
2579               </p></dd>
2580 <dt><span class="term"><span><strong class="command">tkey-dhkey</strong></span></span></dt>
2581 <dd><p>
2582                 The Diffie-Hellman key used by the server
2583                 to generate shared keys with clients using the Diffie-Hellman
2584                 mode
2585                 of <span><strong class="command">TKEY</strong></span>. The server must be
2586                 able to load the
2587                 public and private keys from files in the working directory.
2588                 In
2589                 most cases, the keyname should be the server's host name.
2590               </p></dd>
2591 <dt><span class="term"><span><strong class="command">cache-file</strong></span></span></dt>
2592 <dd><p>
2593                 This is for testing only.  Do not use.
2594               </p></dd>
2595 <dt><span class="term"><span><strong class="command">dump-file</strong></span></span></dt>
2596 <dd><p>
2597                 The pathname of the file the server dumps
2598                 the database to when instructed to do so with
2599                 <span><strong class="command">rndc dumpdb</strong></span>.
2600                 If not specified, the default is <code class="filename">named_dump.db</code>.
2601               </p></dd>
2602 <dt><span class="term"><span><strong class="command">memstatistics-file</strong></span></span></dt>
2603 <dd><p>
2604                 The pathname of the file the server writes memory
2605                 usage statistics to on exit. If not specified,
2606                 the default is <code class="filename">named.memstats</code>.
2607               </p></dd>
2608 <dt><span class="term"><span><strong class="command">pid-file</strong></span></span></dt>
2609 <dd><p>
2610                 The pathname of the file the server writes its process ID
2611                 in. If not specified, the default is
2612                 <code class="filename">/var/run/named/named.pid</code>.
2613                 The PID file is used by programs that want to send signals to
2614                 the running
2615                 name server. Specifying <span><strong class="command">pid-file none</strong></span> disables the
2616                 use of a PID file &#8212; no file will be written and any
2617                 existing one will be removed.  Note that <span><strong class="command">none</strong></span>
2618                 is a keyword, not a filename, and therefore is not enclosed
2619                 in
2620                 double quotes.
2621               </p></dd>
2622 <dt><span class="term"><span><strong class="command">recursing-file</strong></span></span></dt>
2623 <dd><p>
2624                 The pathname of the file the server dumps
2625                 the queries that are currently recursing when instructed
2626                 to do so with <span><strong class="command">rndc recursing</strong></span>.
2627                 If not specified, the default is <code class="filename">named.recursing</code>.
2628               </p></dd>
2629 <dt><span class="term"><span><strong class="command">statistics-file</strong></span></span></dt>
2630 <dd><p>
2631                 The pathname of the file the server appends statistics
2632                 to when instructed to do so using <span><strong class="command">rndc stats</strong></span>.
2633                 If not specified, the default is <code class="filename">named.stats</code> in the
2634                 server's current directory.  The format of the file is
2635                 described
2636                 in <a href="Bv9ARM.ch06.html#statsfile" title="The Statistics File">the section called &#8220;The Statistics File&#8221;</a>.
2637               </p></dd>
2638 <dt><span class="term"><span><strong class="command">bindkeys-file</strong></span></span></dt>
2639 <dd><p>
2640                 The pathname of a file to override the built-in trusted
2641                 keys provided by <span><strong class="command">named</strong></span>.
2642                 See the discussion of <span><strong class="command">dnssec-lookaside</strong></span>
2643                 and <span><strong class="command">dnssec-validation</strong></span> for details. 
2644                 If not specified, the default is
2645                 <code class="filename">/etc/bind.keys</code>.
2646               </p></dd>
2647 <dt><span class="term"><span><strong class="command">secroots-file</strong></span></span></dt>
2648 <dd><p>
2649                 The pathname of the file the server dumps
2650                 security roots to when instructed to do so with
2651                 <span><strong class="command">rndc secroots</strong></span>.
2652                 If not specified, the default is
2653                 <code class="filename">named.secroots</code>.
2654               </p></dd>
2655 <dt><span class="term"><span><strong class="command">session-keyfile</strong></span></span></dt>
2656 <dd><p>
2657                 The pathname of the file into which to write a TSIG
2658                 session key generated by <span><strong class="command">named</strong></span> for use by
2659                 <span><strong class="command">nsupdate -l</strong></span>.  If not specified, the
2660                 default is <code class="filename">/var/run/named/session.key</code>.
2661                 (See <a href="Bv9ARM.ch06.html#dynamic_update_policies" title="Dynamic Update Policies">the section called &#8220;Dynamic Update Policies&#8221;</a>, and in
2662                 particular the discussion of the
2663                 <span><strong class="command">update-policy</strong></span> statement's
2664                 <strong class="userinput"><code>local</code></strong> option for more
2665                 information about this feature.)
2666               </p></dd>
2667 <dt><span class="term"><span><strong class="command">session-keyname</strong></span></span></dt>
2668 <dd><p>
2669                 The key name to use for the TSIG session key.
2670                 If not specified, the default is "local-ddns".
2671               </p></dd>
2672 <dt><span class="term"><span><strong class="command">session-keyalg</strong></span></span></dt>
2673 <dd><p>
2674                 The algorithm to use for the TSIG session key.
2675                 Valid values are hmac-sha1, hmac-sha224, hmac-sha256,
2676                 hmac-sha384, hmac-sha512 and hmac-md5.  If not
2677                 specified, the default is hmac-sha256.
2678               </p></dd>
2679 <dt><span class="term"><span><strong class="command">port</strong></span></span></dt>
2680 <dd><p>
2681                 The UDP/TCP port number the server uses for
2682                 receiving and sending DNS protocol traffic.
2683                 The default is 53.  This option is mainly intended for server
2684                 testing;
2685                 a server using a port other than 53 will not be able to
2686                 communicate with
2687                 the global DNS.
2688               </p></dd>
2689 <dt><span class="term"><span><strong class="command">random-device</strong></span></span></dt>
2690 <dd><p>
2691                 The source of entropy to be used by the server.  Entropy is
2692                 primarily needed
2693                 for DNSSEC operations, such as TKEY transactions and dynamic
2694                 update of signed
2695                 zones.  This options specifies the device (or file) from which
2696                 to read
2697                 entropy.  If this is a file, operations requiring entropy will
2698                 fail when the
2699                 file has been exhausted.  If not specified, the default value
2700                 is
2701                 <code class="filename">/dev/random</code>
2702                 (or equivalent) when present, and none otherwise.  The
2703                 <span><strong class="command">random-device</strong></span> option takes
2704                 effect during
2705                 the initial configuration load at server startup time and
2706                 is ignored on subsequent reloads.
2707               </p></dd>
2708 <dt><span class="term"><span><strong class="command">preferred-glue</strong></span></span></dt>
2709 <dd><p>
2710                 If specified, the listed type (A or AAAA) will be emitted
2711                 before other glue
2712                 in the additional section of a query response.
2713                 The default is not to prefer any type (NONE).
2714               </p></dd>
2715 <dt>
2716 <a name="root_delegation_only"></a><span class="term"><span><strong class="command">root-delegation-only</strong></span></span>
2717 </dt>
2718 <dd>
2719 <p>
2720                 Turn on enforcement of delegation-only in TLDs
2721                 (top level domains) and root zones with an optional
2722                 exclude list.
2723               </p>
2724 <p>
2725                 DS queries are expected to be made to and be answered by
2726                 delegation only zones.  Such queries and responses are
2727                 treated as an exception to delegation-only processing
2728                 and are not converted to NXDOMAIN responses provided
2729                 a CNAME is not discovered at the query name.
2730               </p>
2731 <p>
2732                 If a delegation only zone server also serves a child
2733                 zone it is not always possible to determine whether
2734                 an answer comes from the delegation only zone or the
2735                 child zone.  SOA NS and DNSKEY records are apex
2736                 only records and a matching response that contains
2737                 these records or DS is treated as coming from a
2738                 child zone.  RRSIG records are also examined to see
2739                 if they are signed by a child zone or not.  The
2740                 authority section is also examined to see if there
2741                 is evidence that the answer is from the child zone.
2742                 Answers that are determined to be from a child zone
2743                 are not converted to NXDOMAIN responses.  Despite
2744                 all these checks there is still a possibility of
2745                 false negatives when a child zone is being served.
2746               </p>
2747 <p>
2748                 Similarly false positives can arise from empty nodes
2749                 (no records at the name) in the delegation only zone
2750                 when the query type is not ANY.
2751               </p>
2752 <p>
2753                 Note some TLDs are not delegation only (e.g. "DE", "LV",
2754                 "US" and "MUSEUM").  This list is not exhaustive.
2755               </p>
2756 <pre class="programlisting">
2757 options {
2758         root-delegation-only exclude { "de"; "lv"; "us"; "museum"; };
2759 };
2760 </pre>
2761 </dd>
2762 <dt><span class="term"><span><strong class="command">disable-algorithms</strong></span></span></dt>
2763 <dd><p>
2764                 Disable the specified DNSSEC algorithms at and below the
2765                 specified name.
2766                 Multiple <span><strong class="command">disable-algorithms</strong></span>
2767                 statements are allowed.
2768                 Only the most specific will be applied.
2769               </p></dd>
2770 <dt><span class="term"><span><strong class="command">dnssec-lookaside</strong></span></span></dt>
2771 <dd>
2772 <p>
2773                 When set, <span><strong class="command">dnssec-lookaside</strong></span> provides the
2774                 validator with an alternate method to validate DNSKEY
2775                 records at the top of a zone.  When a DNSKEY is at or
2776                 below a domain specified by the deepest
2777                 <span><strong class="command">dnssec-lookaside</strong></span>, and the normal DNSSEC
2778                 validation has left the key untrusted, the trust-anchor
2779                 will be appended to the key name and a DLV record will be
2780                 looked up to see if it can validate the key.  If the DLV
2781                 record validates a DNSKEY (similarly to the way a DS
2782                 record does) the DNSKEY RRset is deemed to be trusted.
2783               </p>
2784 <p>
2785                 If <span><strong class="command">dnssec-lookaside</strong></span> is set to
2786                 <strong class="userinput"><code>auto</code></strong>, then built-in default
2787                 values for the DLV domain and trust anchor will be
2788                 used, along with a built-in key for validation.
2789               </p>
2790 <p>
2791                 If <span><strong class="command">dnssec-lookaside</strong></span> is set to
2792                 <strong class="userinput"><code>no</code></strong>, then dnssec-lookaside
2793                 is not used.
2794               </p>
2795 <p>
2796                 The default DLV key is stored in the file
2797                 <code class="filename">bind.keys</code>;
2798                 <span><strong class="command">named</strong></span> will load that key at
2799                 startup if <span><strong class="command">dnssec-lookaside</strong></span> is set to
2800                 <code class="constant">auto</code>.  A copy of the file is
2801                 installed along with <acronym class="acronym">BIND</acronym> 9, and is
2802                 current as of the release date.  If the DLV key expires, a
2803                 new copy of <code class="filename">bind.keys</code> can be downloaded
2804                 from <a href="https://www.isc.org/solutions/dlv/" target="_top">https://www.isc.org/solutions/dlv/</a>.
2805               </p>
2806 <p>
2807                 (To prevent problems if <code class="filename">bind.keys</code> is
2808                 not found, the current key is also compiled in to
2809                 <span><strong class="command">named</strong></span>.  Relying on this is not
2810                 recommended, however, as it requires <span><strong class="command">named</strong></span>
2811                 to be recompiled with a new key when the DLV key expires.)
2812               </p>
2813 <p>
2814                 NOTE: <span><strong class="command">named</strong></span> only loads certain specific
2815                 keys from <code class="filename">bind.keys</code>:  those for the
2816                 DLV zone and for the DNS root zone.  The file cannot be
2817                 used to store keys for other zones.
2818               </p>
2819 </dd>
2820 <dt><span class="term"><span><strong class="command">dnssec-must-be-secure</strong></span></span></dt>
2821 <dd><p>
2822                 Specify hierarchies which must be or may not be secure
2823                 (signed and validated).  If <strong class="userinput"><code>yes</code></strong>,
2824                 then <span><strong class="command">named</strong></span> will only accept answers if
2825                 they are secure.  If <strong class="userinput"><code>no</code></strong>, then normal
2826                 DNSSEC validation applies allowing for insecure answers to
2827                 be accepted.  The specified domain must be under a
2828                 <span><strong class="command">trusted-keys</strong></span> or
2829                 <span><strong class="command">managed-keys</strong></span> statement, or
2830                 <span><strong class="command">dnssec-lookaside</strong></span> must be active.
2831               </p></dd>
2832 <dt><span class="term"><span><strong class="command">dns64</strong></span></span></dt>
2833 <dd>
2834 <p>
2835                 This directive instructs <span><strong class="command">named</strong></span> to
2836                 return mapped IPv4 addresses to AAAA queries when
2837                 there are no AAAA records.  It is intended to be
2838                 used in conjunction with a NAT64.  Each
2839                 <span><strong class="command">dns64</strong></span> defines one DNS64 prefix.
2840                 Multiple DNS64 prefixes can be defined.
2841               </p>
2842 <p>
2843                 Compatible IPv6 prefixes have lengths of 32, 40, 48, 56,
2844                 64 and 96 as per RFC 6052.
2845               </p>
2846 <p>
2847                 Additionally a reverse IP6.ARPA zone will be created for
2848                 the prefix to provide a mapping from the IP6.ARPA names
2849                 to the corresponding IN-ADDR.ARPA names using synthesized
2850                 CNAMEs.  <span><strong class="command">dns64-server</strong></span> and
2851                 <span><strong class="command">dns64-contact</strong></span> can be used to specify
2852                 the name of the server and contact for the zones. These
2853                 are settable at the view / options level.  These are
2854                 not settable on a per-prefix basis.
2855               </p>
2856 <p>
2857                 Each <span><strong class="command">dns64</strong></span> supports an optional
2858                 <span><strong class="command">clients</strong></span> ACL that determines which
2859                 clients are affected by this directive.  If not defined,
2860                 it defaults to <strong class="userinput"><code>any;</code></strong>.
2861               </p>
2862 <p>
2863                 Each <span><strong class="command">dns64</strong></span> supports an optional
2864                 <span><strong class="command">mapped</strong></span> ACL that selects which
2865                 IPv4 addresses are to be mapped in the corresponding    
2866                 A RRset.  If not defined it defaults to
2867                 <strong class="userinput"><code>any;</code></strong>.
2868               </p>
2869 <p>
2870                 Normally, DNS64 won't apply to a domain name that
2871                 owns one or more AAAA records; these records will
2872                 simply be returned.  The optional
2873                 <span><strong class="command">exclude</strong></span> ACL allows specification
2874                 of a list of IPv6 addresses that will be ignored
2875                 if they appear in a domain name's AAAA records, and
2876                 DNS64 will be applied to any A records the domain
2877                 name owns.  If not defined, <span><strong class="command">exclude</strong></span>
2878                 defaults to none.
2879               </p>
2880 <p>
2881                 A optional <span><strong class="command">suffix</strong></span> can also
2882                 be defined to set the bits trailing the mapped
2883                 IPv4 address bits.  By default these bits are
2884                 set to <strong class="userinput"><code>::</code></strong>.  The bits
2885                 matching the prefix and mapped IPv4 address
2886                 must be zero.
2887               </p>
2888 <p>
2889                 If <span><strong class="command">recursive-only</strong></span> is set to
2890                 <span><strong class="command">yes</strong></span> the DNS64 synthesis will
2891                 only happen for recursive queries.  The default
2892                 is <span><strong class="command">no</strong></span>.
2893               </p>
2894 <p>
2895                 If <span><strong class="command">break-dnssec</strong></span> is set to
2896                 <span><strong class="command">yes</strong></span> the DNS64 synthesis will
2897                 happen even if the result, if validated, would
2898                 cause a DNSSEC validation failure.  If this option
2899                 is set to <span><strong class="command">no</strong></span> (the default), the DO
2900                 is set on the incoming query, and there are RRSIGs on
2901                 the applicable records, then synthesis will not happen.
2902               </p>
2903 <pre class="programlisting">
2904         acl rfc1918 { 10/8; 192.168/16; 172.16/12; };
2905
2906         dns64 64:FF9B::/96 {
2907                 clients { any; };
2908                 mapped { !rfc1918; any; };
2909                 exclude { 64:FF9B::/96; ::ffff:0000:0000/96; };
2910                 suffix ::;
2911         };
2912 </pre>
2913 </dd>
2914 <dt><span class="term"><span><strong class="command">dnssec-update-mode</strong></span></span></dt>
2915 <dd>
2916 <p>
2917                   If this option is set to its default value of
2918                   <code class="literal">maintain</code> in a zone of type
2919                   <code class="literal">master</code> which is DNSSEC-signed
2920                   and configured to allow dynamic updates (see
2921                   <a href="Bv9ARM.ch06.html#dynamic_update_policies" title="Dynamic Update Policies">the section called &#8220;Dynamic Update Policies&#8221;</a>), and
2922                   if <span><strong class="command">named</strong></span> has access to the
2923                   private signing key(s) for the zone, then
2924                   <span><strong class="command">named</strong></span> will automatically sign all new
2925                   or changed records and maintain signatures for the zone
2926                   by regenerating RRSIG records whenever they approach
2927                   their expiration date.
2928                 </p>
2929 <p>
2930                   If the option is changed to <code class="literal">no-resign</code>,
2931                   then <span><strong class="command">named</strong></span> will sign all new or
2932                   changed records, but scheduled maintenance of
2933                   signatures is disabled.
2934                 </p>
2935 <p>
2936                   With either of these settings, <span><strong class="command">named</strong></span>
2937                   will reject updates to a DNSSEC-signed zone when the
2938                   signing keys are inactive or unavailable to
2939                   <span><strong class="command">named</strong></span>.  (A planned third option,
2940                   <code class="literal">external</code>, will disable all automatic
2941                   signing and allow DNSSEC data to be submitted into a zone
2942                   via dynamic update; this is not yet implemented.)
2943                 </p>
2944 </dd>
2945 <dt><span class="term"><span><strong class="command">zone-statistics</strong></span></span></dt>
2946 <dd>
2947 <p>
2948                 If <strong class="userinput"><code>full</code></strong>, the server will collect
2949                 statistical data on all zones (unless specifically
2950                 turned off on a per-zone basis by specifying
2951                 <span><strong class="command">zone-statistics terse</strong></span> or
2952                 <span><strong class="command">zone-statistics none</strong></span>
2953                 in the <span><strong class="command">zone</strong></span> statement).
2954                 The default is <strong class="userinput"><code>terse</code></strong>, providing
2955                 minimal statistics on zones (including name and
2956                 current serial number, but not query type
2957                 counters).
2958               </p>
2959 <p>
2960                 These statistics may be accessed via the
2961                 <span><strong class="command">statistics-channel</strong></span> or
2962                 using <span><strong class="command">rndc stats</strong></span>, which
2963                 will dump them to the file listed
2964                 in the <span><strong class="command">statistics-file</strong></span>.  See
2965                 also <a href="Bv9ARM.ch06.html#statsfile" title="The Statistics File">the section called &#8220;The Statistics File&#8221;</a>.
2966               </p>
2967 <p>
2968                 For backward compatibility with earlier versions
2969                 of BIND 9, the <span><strong class="command">zone-statistics</strong></span>
2970                 option can also accept <strong class="userinput"><code>yes</code></strong>
2971                 or <strong class="userinput"><code>no</code></strong>, which have the same
2972                 effect as <strong class="userinput"><code>full</code></strong> and
2973                 <strong class="userinput"><code>terse</code></strong>, respectively.
2974               </p>
2975 </dd>
2976 </dl></div>
2977 <div class="sect3" lang="en">
2978 <div class="titlepage"><div><div><h4 class="title">
2979 <a name="boolean_options"></a>Boolean Options</h4></div></div></div>
2980 <div class="variablelist"><dl>
2981 <dt><span class="term"><span><strong class="command">allow-new-zones</strong></span></span></dt>
2982 <dd><p>
2983                   If <strong class="userinput"><code>yes</code></strong>, then zones can be
2984                   added at runtime via <span><strong class="command">rndc addzone</strong></span>
2985                   or deleted via <span><strong class="command">rndc delzone</strong></span>.
2986                   The default is <strong class="userinput"><code>no</code></strong>.
2987                 </p></dd>
2988 <dt><span class="term"><span><strong class="command">auth-nxdomain</strong></span></span></dt>
2989 <dd><p>
2990                   If <strong class="userinput"><code>yes</code></strong>, then the <span><strong class="command">AA</strong></span> bit
2991                   is always set on NXDOMAIN responses, even if the server is
2992                   not actually
2993                   authoritative. The default is <strong class="userinput"><code>no</code></strong>;
2994                   this is
2995                   a change from <acronym class="acronym">BIND</acronym> 8. If you
2996                   are using very old DNS software, you
2997                   may need to set it to <strong class="userinput"><code>yes</code></strong>.
2998                 </p></dd>
2999 <dt><span class="term"><span><strong class="command">deallocate-on-exit</strong></span></span></dt>
3000 <dd><p>
3001                   This option was used in <acronym class="acronym">BIND</acronym>
3002                   8 to enable checking
3003                   for memory leaks on exit. <acronym class="acronym">BIND</acronym> 9 ignores the option and always performs
3004                   the checks.
3005                 </p></dd>
3006 <dt><span class="term"><span><strong class="command">memstatistics</strong></span></span></dt>
3007 <dd><p>
3008                   Write memory statistics to the file specified by
3009                   <span><strong class="command">memstatistics-file</strong></span> at exit.
3010                   The default is <strong class="userinput"><code>no</code></strong> unless
3011                   '-m record' is specified on the command line in
3012                   which case it is <strong class="userinput"><code>yes</code></strong>.
3013                 </p></dd>
3014 <dt><span class="term"><span><strong class="command">dialup</strong></span></span></dt>
3015 <dd>
3016 <p>
3017                   If <strong class="userinput"><code>yes</code></strong>, then the
3018                   server treats all zones as if they are doing zone transfers
3019                   across
3020                   a dial-on-demand dialup link, which can be brought up by
3021                   traffic
3022                   originating from this server. This has different effects
3023                   according
3024                   to zone type and concentrates the zone maintenance so that
3025                   it all
3026                   happens in a short interval, once every <span><strong class="command">heartbeat-interval</strong></span> and
3027                   hopefully during the one call. It also suppresses some of
3028                   the normal
3029                   zone maintenance traffic. The default is <strong class="userinput"><code>no</code></strong>.
3030                 </p>
3031 <p>
3032                   The <span><strong class="command">dialup</strong></span> option
3033                   may also be specified in the <span><strong class="command">view</strong></span> and
3034                   <span><strong class="command">zone</strong></span> statements,
3035                   in which case it overrides the global <span><strong class="command">dialup</strong></span>
3036                   option.
3037                 </p>
3038 <p>
3039                   If the zone is a master zone, then the server will send out a
3040                   NOTIFY
3041                   request to all the slaves (default). This should trigger the
3042                   zone serial
3043                   number check in the slave (providing it supports NOTIFY)
3044                   allowing the slave
3045                   to verify the zone while the connection is active.
3046                   The set of servers to which NOTIFY is sent can be controlled
3047                   by
3048                   <span><strong class="command">notify</strong></span> and <span><strong class="command">also-notify</strong></span>.
3049                 </p>
3050 <p>
3051                   If the
3052                   zone is a slave or stub zone, then the server will suppress
3053                   the regular
3054                   "zone up to date" (refresh) queries and only perform them
3055                   when the
3056                   <span><strong class="command">heartbeat-interval</strong></span> expires in
3057                   addition to sending
3058                   NOTIFY requests.
3059                 </p>
3060 <p>
3061                   Finer control can be achieved by using
3062                   <strong class="userinput"><code>notify</code></strong> which only sends NOTIFY
3063                   messages,
3064                   <strong class="userinput"><code>notify-passive</code></strong> which sends NOTIFY
3065                   messages and
3066                   suppresses the normal refresh queries, <strong class="userinput"><code>refresh</code></strong>
3067                   which suppresses normal refresh processing and sends refresh
3068                   queries
3069                   when the <span><strong class="command">heartbeat-interval</strong></span>
3070                   expires, and
3071                   <strong class="userinput"><code>passive</code></strong> which just disables normal
3072                   refresh
3073                   processing.
3074                 </p>
3075 <div class="informaltable"><table border="1">
3076 <colgroup>
3077 <col>
3078 <col>
3079 <col>
3080 <col>
3081 </colgroup>
3082 <tbody>
3083 <tr>
3084 <td>
3085                           <p>
3086                             dialup mode
3087                           </p>
3088                         </td>
3089 <td>
3090                           <p>
3091                             normal refresh
3092                           </p>
3093                         </td>
3094 <td>
3095                           <p>
3096                             heart-beat refresh
3097                           </p>
3098                         </td>
3099 <td>
3100                           <p>
3101                             heart-beat notify
3102                           </p>
3103                         </td>
3104 </tr>
3105 <tr>
3106 <td>
3107                           <p><span><strong class="command">no</strong></span> (default)</p>
3108                         </td>
3109 <td>
3110                           <p>
3111                             yes
3112                           </p>
3113                         </td>
3114 <td>
3115                           <p>
3116                             no
3117                           </p>
3118                         </td>
3119 <td>
3120                           <p>
3121                             no
3122                           </p>
3123                         </td>
3124 </tr>
3125 <tr>
3126 <td>
3127                           <p><span><strong class="command">yes</strong></span></p>
3128                         </td>
3129 <td>
3130                           <p>
3131                             no
3132                           </p>
3133                         </td>
3134 <td>
3135                           <p>
3136                             yes
3137                           </p>
3138                         </td>
3139 <td>
3140                           <p>
3141                             yes
3142                           </p>
3143                         </td>
3144 </tr>
3145 <tr>
3146 <td>
3147                           <p><span><strong class="command">notify</strong></span></p>
3148                         </td>
3149 <td>
3150                           <p>
3151                             yes
3152                           </p>
3153                         </td>
3154 <td>
3155                           <p>
3156                             no
3157                           </p>
3158                         </td>
3159 <td>
3160                           <p>
3161                             yes
3162                           </p>
3163                         </td>
3164 </tr>
3165 <tr>
3166 <td>
3167                           <p><span><strong class="command">refresh</strong></span></p>
3168                         </td>
3169 <td>
3170                           <p>
3171                             no
3172                           </p>
3173                         </td>
3174 <td>
3175                           <p>
3176                             yes
3177                           </p>
3178                         </td>
3179 <td>
3180                           <p>
3181                             no
3182                           </p>
3183                         </td>
3184 </tr>
3185 <tr>
3186 <td>
3187                           <p><span><strong class="command">passive</strong></span></p>
3188                         </td>
3189 <td>
3190                           <p>
3191                             no
3192                           </p>
3193                         </td>
3194 <td>
3195                           <p>
3196                             no
3197                           </p>
3198                         </td>
3199 <td>
3200                           <p>
3201                             no
3202                           </p>
3203                         </td>
3204 </tr>
3205 <tr>
3206 <td>
3207                           <p><span><strong class="command">notify-passive</strong></span></p>
3208                         </td>
3209 <td>
3210                           <p>
3211                             no
3212                           </p>
3213                         </td>
3214 <td>
3215                           <p>
3216                             no
3217                           </p>
3218                         </td>
3219 <td>
3220                           <p>
3221                             yes
3222                           </p>
3223                         </td>
3224 </tr>
3225 </tbody>
3226 </table></div>
3227 <p>
3228                   Note that normal NOTIFY processing is not affected by
3229                   <span><strong class="command">dialup</strong></span>.
3230                 </p>
3231 </dd>
3232 <dt><span class="term"><span><strong class="command">fake-iquery</strong></span></span></dt>
3233 <dd><p>
3234                   In <acronym class="acronym">BIND</acronym> 8, this option
3235                   enabled simulating the obsolete DNS query type
3236                   IQUERY. <acronym class="acronym">BIND</acronym> 9 never does
3237                   IQUERY simulation.
3238                 </p></dd>
3239 <dt><span class="term"><span><strong class="command">fetch-glue</strong></span></span></dt>
3240 <dd><p>
3241                   This option is obsolete.
3242                   In BIND 8, <strong class="userinput"><code>fetch-glue yes</code></strong>
3243                   caused the server to attempt to fetch glue resource records
3244                   it
3245                   didn't have when constructing the additional
3246                   data section of a response.  This is now considered a bad
3247                   idea
3248                   and BIND 9 never does it.
3249                 </p></dd>
3250 <dt><span class="term"><span><strong class="command">flush-zones-on-shutdown</strong></span></span></dt>
3251 <dd><p>
3252                   When the nameserver exits due receiving SIGTERM,
3253                   flush or do not flush any pending zone writes.  The default
3254                   is
3255                   <span><strong class="command">flush-zones-on-shutdown</strong></span> <strong class="userinput"><code>no</code></strong>.
3256                 </p></dd>
3257 <dt><span class="term"><span><strong class="command">has-old-clients</strong></span></span></dt>
3258 <dd><p>
3259                   This option was incorrectly implemented
3260                   in <acronym class="acronym">BIND</acronym> 8, and is ignored by <acronym class="acronym">BIND</acronym> 9.
3261                   To achieve the intended effect
3262                   of
3263                   <span><strong class="command">has-old-clients</strong></span> <strong class="userinput"><code>yes</code></strong>, specify
3264                   the two separate options <span><strong class="command">auth-nxdomain</strong></span> <strong class="userinput"><code>yes</code></strong>
3265                   and <span><strong class="command">rfc2308-type1</strong></span> <strong class="userinput"><code>no</code></strong> instead.
3266                 </p></dd>
3267 <dt><span class="term"><span><strong class="command">host-statistics</strong></span></span></dt>
3268 <dd><p>
3269                   In BIND 8, this enables keeping of
3270                   statistics for every host that the name server interacts
3271                   with.
3272                   Not implemented in BIND 9.
3273                 </p></dd>
3274 <dt><span class="term"><span><strong class="command">maintain-ixfr-base</strong></span></span></dt>
3275 <dd><p>
3276                   <span class="emphasis"><em>This option is obsolete</em></span>.
3277                   It was used in <acronym class="acronym">BIND</acronym> 8 to
3278                   determine whether a transaction log was
3279                   kept for Incremental Zone Transfer. <acronym class="acronym">BIND</acronym> 9 maintains a transaction
3280                   log whenever possible.  If you need to disable outgoing
3281                   incremental zone
3282                   transfers, use <span><strong class="command">provide-ixfr</strong></span> <strong class="userinput"><code>no</code></strong>.
3283                 </p></dd>
3284 <dt><span class="term"><span><strong class="command">minimal-responses</strong></span></span></dt>
3285 <dd><p>
3286                   If <strong class="userinput"><code>yes</code></strong>, then when generating
3287                   responses the server will only add records to the authority
3288                   and additional data sections when they are required (e.g.
3289                   delegations, negative responses).  This may improve the
3290                   performance of the server.
3291                   The default is <strong class="userinput"><code>no</code></strong>.
3292                 </p></dd>
3293 <dt><span class="term"><span><strong class="command">multiple-cnames</strong></span></span></dt>
3294 <dd><p>
3295                   This option was used in <acronym class="acronym">BIND</acronym> 8 to allow
3296                   a domain name to have multiple CNAME records in violation of
3297                   the DNS standards.  <acronym class="acronym">BIND</acronym> 9.2 onwards
3298                   always strictly enforces the CNAME rules both in master
3299                   files and dynamic updates.
3300                 </p></dd>
3301 <dt><span class="term"><span><strong class="command">notify</strong></span></span></dt>
3302 <dd>
3303 <p>
3304                   If <strong class="userinput"><code>yes</code></strong> (the default),
3305                   DNS NOTIFY messages are sent when a zone the server is
3306                   authoritative for
3307                   changes, see <a href="Bv9ARM.ch04.html#notify" title="Notify">the section called &#8220;Notify&#8221;</a>.  The messages are
3308                   sent to the
3309                   servers listed in the zone's NS records (except the master
3310                   server identified
3311                   in the SOA MNAME field), and to any servers listed in the
3312                   <span><strong class="command">also-notify</strong></span> option.
3313                 </p>
3314 <p>
3315                   If <strong class="userinput"><code>master-only</code></strong>, notifies are only
3316                   sent
3317                   for master zones.
3318                   If <strong class="userinput"><code>explicit</code></strong>, notifies are sent only
3319                   to
3320                   servers explicitly listed using <span><strong class="command">also-notify</strong></span>.
3321                   If <strong class="userinput"><code>no</code></strong>, no notifies are sent.
3322                 </p>
3323 <p>
3324                   The <span><strong class="command">notify</strong></span> option may also be
3325                   specified in the <span><strong class="command">zone</strong></span>
3326                   statement,
3327                   in which case it overrides the <span><strong class="command">options notify</strong></span> statement.
3328                   It would only be necessary to turn off this option if it
3329                   caused slaves
3330                   to crash.
3331                 </p>
3332 </dd>
3333 <dt><span class="term"><span><strong class="command">notify-to-soa</strong></span></span></dt>
3334 <dd><p>
3335                   If <strong class="userinput"><code>yes</code></strong> do not check the nameservers
3336                   in the NS RRset against the SOA MNAME.  Normally a NOTIFY
3337                   message is not sent to the SOA MNAME (SOA ORIGIN) as it is
3338                   supposed to contain the name of the ultimate master.
3339                   Sometimes, however, a slave is listed as the SOA MNAME in
3340                   hidden master configurations and in that case you would
3341                   want the ultimate master to still send NOTIFY messages to
3342                   all the nameservers listed in the NS RRset.
3343                 </p></dd>
3344 <dt><span class="term"><span><strong class="command">recursion</strong></span></span></dt>
3345 <dd><p>
3346                   If <strong class="userinput"><code>yes</code></strong>, and a
3347                   DNS query requests recursion, then the server will attempt
3348                   to do
3349                   all the work required to answer the query. If recursion is
3350                   off
3351                   and the server does not already know the answer, it will
3352                   return a
3353                   referral response. The default is
3354                   <strong class="userinput"><code>yes</code></strong>.
3355                   Note that setting <span><strong class="command">recursion no</strong></span> does not prevent
3356                   clients from getting data from the server's cache; it only
3357                   prevents new data from being cached as an effect of client
3358                   queries.
3359                   Caching may still occur as an effect the server's internal
3360                   operation, such as NOTIFY address lookups.
3361                   See also <span><strong class="command">fetch-glue</strong></span> above.
3362                 </p></dd>
3363 <dt><span class="term"><span><strong class="command">request-nsid</strong></span></span></dt>
3364 <dd><p>
3365                   If <strong class="userinput"><code>yes</code></strong>, then an empty EDNS(0)
3366                   NSID (Name Server Identifier) option is sent with all 
3367                   queries to authoritative name servers during iterative
3368                   resolution. If the authoritative server returns an NSID
3369                   option in its response, then its contents are logged in
3370                   the <span><strong class="command">resolver</strong></span> category at level
3371                   <span><strong class="command">info</strong></span>.
3372                   The default is <strong class="userinput"><code>no</code></strong>.
3373                 </p></dd>
3374 <dt><span class="term"><span><strong class="command">rfc2308-type1</strong></span></span></dt>
3375 <dd>
3376 <p>
3377                   Setting this to <strong class="userinput"><code>yes</code></strong> will
3378                   cause the server to send NS records along with the SOA
3379                   record for negative
3380                   answers. The default is <strong class="userinput"><code>no</code></strong>.
3381                 </p>
3382 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
3383 <h3 class="title">Note</h3>
3384 <p>
3385                     Not yet implemented in <acronym class="acronym">BIND</acronym>
3386                     9.
3387                   </p>
3388 </div>
3389 </dd>
3390 <dt><span class="term"><span><strong class="command">use-id-pool</strong></span></span></dt>
3391 <dd><p>
3392                   <span class="emphasis"><em>This option is obsolete</em></span>.
3393                   <acronym class="acronym">BIND</acronym> 9 always allocates query
3394                   IDs from a pool.
3395                 </p></dd>
3396 <dt><span class="term"><span><strong class="command">use-ixfr</strong></span></span></dt>
3397 <dd><p>
3398                   <span class="emphasis"><em>This option is obsolete</em></span>.
3399                   If you need to disable IXFR to a particular server or
3400                   servers, see
3401                   the information on the <span><strong class="command">provide-ixfr</strong></span> option
3402                   in <a href="Bv9ARM.ch06.html#server_statement_definition_and_usage" title="server Statement Definition and
3403             Usage">the section called &#8220;<span><strong class="command">server</strong></span> Statement Definition and
3404             Usage&#8221;</a>.
3405                   See also
3406                   <a href="Bv9ARM.ch04.html#incremental_zone_transfers" title="Incremental Zone Transfers (IXFR)">the section called &#8220;Incremental Zone Transfers (IXFR)&#8221;</a>.
3407                 </p></dd>
3408 <dt><span class="term"><span><strong class="command">provide-ixfr</strong></span></span></dt>
3409 <dd><p>
3410                   See the description of
3411                   <span><strong class="command">provide-ixfr</strong></span> in
3412                   <a href="Bv9ARM.ch06.html#server_statement_definition_and_usage" title="server Statement Definition and
3413             Usage">the section called &#8220;<span><strong class="command">server</strong></span> Statement Definition and
3414             Usage&#8221;</a>.
3415                 </p></dd>
3416 <dt><span class="term"><span><strong class="command">request-ixfr</strong></span></span></dt>
3417 <dd><p>
3418                   See the description of
3419                   <span><strong class="command">request-ixfr</strong></span> in
3420                   <a href="Bv9ARM.ch06.html#server_statement_definition_and_usage" title="server Statement Definition and
3421             Usage">the section called &#8220;<span><strong class="command">server</strong></span> Statement Definition and
3422             Usage&#8221;</a>.
3423                 </p></dd>
3424 <dt><span class="term"><span><strong class="command">treat-cr-as-space</strong></span></span></dt>
3425 <dd><p>
3426                   This option was used in <acronym class="acronym">BIND</acronym>
3427                   8 to make
3428                   the server treat carriage return ("<span><strong class="command">\r</strong></span>") characters the same way
3429                   as a space or tab character,
3430                   to facilitate loading of zone files on a UNIX system that
3431                   were generated
3432                   on an NT or DOS machine. In <acronym class="acronym">BIND</acronym> 9, both UNIX "<span><strong class="command">\n</strong></span>"
3433                   and NT/DOS "<span><strong class="command">\r\n</strong></span>" newlines
3434                   are always accepted,
3435                   and the option is ignored.
3436                 </p></dd>
3437 <dt>
3438 <span class="term"><span><strong class="command">additional-from-auth</strong></span>, </span><span class="term"><span><strong class="command">additional-from-cache</strong></span></span>
3439 </dt>
3440 <dd>
3441 <p>
3442                   These options control the behavior of an authoritative
3443                   server when
3444                   answering queries which have additional data, or when
3445                   following CNAME
3446                   and DNAME chains.
3447                 </p>
3448 <p>
3449                   When both of these options are set to <strong class="userinput"><code>yes</code></strong>
3450                   (the default) and a
3451                   query is being answered from authoritative data (a zone
3452                   configured into the server), the additional data section of
3453                   the
3454                   reply will be filled in using data from other authoritative
3455                   zones
3456                   and from the cache.  In some situations this is undesirable,
3457                   such
3458                   as when there is concern over the correctness of the cache,
3459                   or
3460                   in servers where slave zones may be added and modified by
3461                   untrusted third parties.  Also, avoiding
3462                   the search for this additional data will speed up server
3463                   operations
3464                   at the possible expense of additional queries to resolve
3465                   what would
3466                   otherwise be provided in the additional section.
3467                 </p>
3468 <p>
3469                   For example, if a query asks for an MX record for host <code class="literal">foo.example.com</code>,
3470                   and the record found is "<code class="literal">MX 10 mail.example.net</code>", normally the address
3471                   records (A and AAAA) for <code class="literal">mail.example.net</code> will be provided as well,
3472                   if known, even though they are not in the example.com zone.
3473                   Setting these options to <span><strong class="command">no</strong></span>
3474                   disables this behavior and makes
3475                   the server only search for additional data in the zone it
3476                   answers from.
3477                 </p>
3478 <p>
3479                   These options are intended for use in authoritative-only
3480                   servers, or in authoritative-only views.  Attempts to set
3481                   them to <span><strong class="command">no</strong></span> without also
3482                   specifying
3483                   <span><strong class="command">recursion no</strong></span> will cause the
3484                   server to
3485                   ignore the options and log a warning message.
3486                 </p>
3487 <p>
3488                   Specifying <span><strong class="command">additional-from-cache no</strong></span> actually
3489                   disables the use of the cache not only for additional data
3490                   lookups
3491                   but also when looking up the answer.  This is usually the
3492                   desired
3493                   behavior in an authoritative-only server where the
3494                   correctness of
3495                   the cached data is an issue.
3496                 </p>
3497 <p>
3498                   When a name server is non-recursively queried for a name
3499                   that is not
3500                   below the apex of any served zone, it normally answers with
3501                   an
3502                   "upwards referral" to the root servers or the servers of
3503                   some other
3504                   known parent of the query name.  Since the data in an
3505                   upwards referral
3506                   comes from the cache, the server will not be able to provide
3507                   upwards
3508                   referrals when <span><strong class="command">additional-from-cache no</strong></span>
3509                   has been specified.  Instead, it will respond to such
3510                   queries
3511                   with REFUSED.  This should not cause any problems since
3512                   upwards referrals are not required for the resolution
3513                   process.
3514                 </p>
3515 </dd>
3516 <dt><span class="term"><span><strong class="command">match-mapped-addresses</strong></span></span></dt>
3517 <dd>
3518 <p>
3519                   If <strong class="userinput"><code>yes</code></strong>, then an
3520                   IPv4-mapped IPv6 address will match any address match
3521                   list entries that match the corresponding IPv4 address.
3522                 </p>
3523 <p>
3524                   This option was introduced to work around a kernel quirk
3525                   in some operating systems that causes IPv4 TCP
3526                   connections, such as zone transfers, to be accepted on an
3527                   IPv6 socket using mapped addresses.  This caused address
3528                   match lists designed for IPv4 to fail to match.  However,
3529                   <span><strong class="command">named</strong></span> now solves this problem
3530                   internally.  The use of this option is discouraged.
3531                 </p>
3532 </dd>
3533 <dt><span class="term"><span><strong class="command">filter-aaaa-on-v4</strong></span></span></dt>
3534 <dd>
3535 <p>
3536                   This option is only available when
3537                   <acronym class="acronym">BIND</acronym> 9 is compiled with the
3538                   <strong class="userinput"><code>--enable-filter-aaaa</code></strong> option on the
3539                   "configure" command line.  It is intended to help the
3540                   transition from IPv4 to IPv6 by not giving IPv6 addresses
3541                   to DNS clients unless they have connections to the IPv6
3542                   Internet.  This is not recommended unless absolutely
3543                   necessary.  The default is <strong class="userinput"><code>no</code></strong>.
3544                   The <span><strong class="command">filter-aaaa-on-v4</strong></span> option
3545                   may also be specified in <span><strong class="command">view</strong></span> statements
3546                   to override the global <span><strong class="command">filter-aaaa-on-v4</strong></span>
3547                   option.
3548                 </p>
3549 <p>
3550                   If <strong class="userinput"><code>yes</code></strong>,
3551                   the DNS client is at an IPv4 address, in <span><strong class="command">filter-aaaa</strong></span>,
3552                   and if the response does not include DNSSEC signatures, 
3553                   then all AAAA records are deleted from the response.
3554                   This filtering applies to all responses and not only
3555                   authoritative responses.
3556                 </p>
3557 <p>
3558                   If <strong class="userinput"><code>break-dnssec</code></strong>,
3559                   then AAAA records are deleted even when dnssec is enabled.
3560                   As suggested by the name, this makes the response not verify,
3561                   because the DNSSEC protocol is designed detect deletions.
3562                 </p>
3563 <p>
3564                   This mechanism can erroneously cause other servers to 
3565                   not give AAAA records to their clients.  
3566                   A recursing server with both IPv6 and IPv4 network connections
3567                   that queries an authoritative server using this mechanism
3568                   via IPv4 will be denied AAAA records even if its client is
3569                   using IPv6.
3570                 </p>
3571 <p>
3572                   This mechanism is applied to authoritative as well as
3573                   non-authoritative records.
3574                   A client using IPv4 that is not allowed recursion can
3575                   erroneously be given AAAA records because the server is not
3576                   allowed to check for A records.
3577                 </p>
3578 <p>
3579                   Some AAAA records are given to IPv4 clients in glue records.
3580                   IPv4 clients that are servers can then erroneously
3581                   answer requests for AAAA records received via IPv4.
3582                 </p>
3583 </dd>
3584 <dt><span class="term"><span><strong class="command">ixfr-from-differences</strong></span></span></dt>
3585 <dd>
3586 <p>
3587                   When <strong class="userinput"><code>yes</code></strong> and the server loads a new
3588                   version of a master zone from its zone file or receives a
3589                   new version of a slave file via zone transfer, it will
3590                   compare the new version to the previous one and calculate
3591                   a set of differences.  The differences are then logged in
3592                   the zone's journal file such that the changes can be
3593                   transmitted to downstream slaves as an incremental zone
3594                   transfer.
3595                 </p>
3596 <p>
3597                   By allowing incremental zone transfers to be used for
3598                   non-dynamic zones, this option saves bandwidth at the
3599                   expense of increased CPU and memory consumption at the
3600                   master.
3601                   In particular, if the new version of a zone is completely
3602                   different from the previous one, the set of differences
3603                   will be of a size comparable to the combined size of the
3604                   old and new zone version, and the server will need to
3605                   temporarily allocate memory to hold this complete
3606                   difference set.
3607                 </p>
3608 <p><span><strong class="command">ixfr-from-differences</strong></span>
3609                   also accepts <span><strong class="command">master</strong></span> and
3610                   <span><strong class="command">slave</strong></span> at the view and options
3611                   levels which causes
3612                   <span><strong class="command">ixfr-from-differences</strong></span> to be enabled for
3613                   all <span><strong class="command">master</strong></span> or
3614                   <span><strong class="command">slave</strong></span> zones respectively.
3615                   It is off by default.
3616                 </p>
3617 </dd>
3618 <dt><span class="term"><span><strong class="command">multi-master</strong></span></span></dt>
3619 <dd><p>
3620                   This should be set when you have multiple masters for a zone
3621                   and the
3622                   addresses refer to different machines.  If <strong class="userinput"><code>yes</code></strong>, <span><strong class="command">named</strong></span> will
3623                   not log
3624                   when the serial number on the master is less than what <span><strong class="command">named</strong></span>
3625                   currently
3626                   has.  The default is <strong class="userinput"><code>no</code></strong>.
3627                 </p></dd>
3628 <dt><span class="term"><span><strong class="command">dnssec-enable</strong></span></span></dt>
3629 <dd><p>
3630                   Enable DNSSEC support in <span><strong class="command">named</strong></span>.  Unless set to <strong class="userinput"><code>yes</code></strong>,
3631                   <span><strong class="command">named</strong></span> behaves as if it does not support DNSSEC.
3632                   The default is <strong class="userinput"><code>yes</code></strong>.
3633                 </p></dd>
3634 <dt><span class="term"><span><strong class="command">dnssec-validation</strong></span></span></dt>
3635 <dd><p>
3636                   Enable DNSSEC validation in <span><strong class="command">named</strong></span>.
3637                   Note <span><strong class="command">dnssec-enable</strong></span> also needs to be
3638                   set to <strong class="userinput"><code>yes</code></strong> to be effective.
3639                   If set to <strong class="userinput"><code>no</code></strong>, DNSSEC validation
3640                   is disabled.  If set to <strong class="userinput"><code>auto</code></strong>,
3641                   DNSSEC validation is enabled, and a default
3642                   trust-anchor for the DNS root zone is used.  If set to
3643                   <strong class="userinput"><code>yes</code></strong>, DNSSEC validation is enabled,
3644                   but a trust anchor must be manually configured using
3645                   a <span><strong class="command">trusted-keys</strong></span> or
3646                   <span><strong class="command">managed-keys</strong></span> statement.  The default
3647                   is <strong class="userinput"><code>yes</code></strong>.
3648                 </p></dd>
3649 <dt><span class="term"><span><strong class="command">dnssec-accept-expired</strong></span></span></dt>
3650 <dd><p>
3651                   Accept expired signatures when verifying DNSSEC signatures.
3652                   The default is <strong class="userinput"><code>no</code></strong>.
3653                   Setting this option to <strong class="userinput"><code>yes</code></strong>
3654                   leaves <span><strong class="command">named</strong></span> vulnerable to
3655                   replay attacks.
3656                 </p></dd>
3657 <dt><span class="term"><span><strong class="command">querylog</strong></span></span></dt>
3658 <dd><p>
3659                   Specify whether query logging should be started when <span><strong class="command">named</strong></span>
3660                   starts.
3661                   If <span><strong class="command">querylog</strong></span> is not specified,
3662                   then the query logging
3663                   is determined by the presence of the logging category <span><strong class="command">queries</strong></span>.
3664                 </p></dd>
3665 <dt><span class="term"><span><strong class="command">check-names</strong></span></span></dt>
3666 <dd>
3667 <p>
3668                   This option is used to restrict the character set and syntax
3669                   of
3670                   certain domain names in master files and/or DNS responses
3671                   received
3672                   from the network.  The default varies according to usage
3673                   area.  For
3674                   <span><strong class="command">master</strong></span> zones the default is <span><strong class="command">fail</strong></span>.
3675                   For <span><strong class="command">slave</strong></span> zones the default
3676                   is <span><strong class="command">warn</strong></span>.
3677                   For answers received from the network (<span><strong class="command">response</strong></span>)
3678                   the default is <span><strong class="command">ignore</strong></span>.
3679                 </p>
3680 <p>
3681                   The rules for legal hostnames and mail domains are derived
3682                   from RFC 952 and RFC 821 as modified by RFC 1123.
3683                 </p>
3684 <p><span><strong class="command">check-names</strong></span>
3685                   applies to the owner names of A, AAAA and MX records.
3686                   It also applies to the domain names in the RDATA of NS, SOA,
3687                   MX, and SRV records.
3688                   It also applies to the RDATA of PTR records where the owner
3689                   name indicated that it is a reverse lookup of a hostname
3690                   (the owner name ends in IN-ADDR.ARPA, IP6.ARPA, or IP6.INT).
3691                 </p>
3692 </dd>
3693 <dt><span class="term"><span><strong class="command">check-dup-records</strong></span></span></dt>
3694 <dd><p>
3695                   Check master zones for records that are treated as different
3696                   by DNSSEC but are semantically equal in plain DNS.  The
3697                   default is to <span><strong class="command">warn</strong></span>.  Other possible
3698                   values are <span><strong class="command">fail</strong></span> and
3699                   <span><strong class="command">ignore</strong></span>.
3700                 </p></dd>
3701 <dt><span class="term"><span><strong class="command">check-mx</strong></span></span></dt>
3702 <dd><p>
3703                   Check whether the MX record appears to refer to a IP address.
3704                   The default is to <span><strong class="command">warn</strong></span>.  Other possible
3705                   values are <span><strong class="command">fail</strong></span> and
3706                   <span><strong class="command">ignore</strong></span>.
3707                 </p></dd>
3708 <dt><span class="term"><span><strong class="command">check-wildcard</strong></span></span></dt>
3709 <dd><p>
3710                   This option is used to check for non-terminal wildcards.
3711                   The use of non-terminal wildcards is almost always as a
3712                   result of a failure
3713                   to understand the wildcard matching algorithm (RFC 1034).
3714                   This option
3715                   affects master zones.  The default (<span><strong class="command">yes</strong></span>) is to check
3716                   for non-terminal wildcards and issue a warning.
3717                 </p></dd>
3718 <dt><span class="term"><span><strong class="command">check-integrity</strong></span></span></dt>
3719 <dd>
3720 <p>
3721                   Perform post load zone integrity checks on master
3722                   zones.  This checks that MX and SRV records refer
3723                   to address (A or AAAA) records and that glue
3724                   address records exist for delegated zones.  For
3725                   MX and SRV records only in-zone hostnames are
3726                   checked (for out-of-zone hostnames use
3727                   <span><strong class="command">named-checkzone</strong></span>).
3728                   For NS records only names below top of zone are
3729                   checked (for out-of-zone names and glue consistency
3730                   checks use <span><strong class="command">named-checkzone</strong></span>).
3731                   The default is <span><strong class="command">yes</strong></span>.
3732                 </p>
3733 <p>
3734                   The use of the SPF record for publishing Sender
3735                   Policy Framework is deprecated as the migration
3736                   from using TXT records to SPF records was abandoned.
3737                   Enabling this option also checks that a TXT Sender
3738                   Policy Framework record exists (starts with "v=spf1")
3739                   if there is an SPF record. Warnings are emitted if the
3740                   TXT record does not exist and can be suppressed with
3741                   <span><strong class="command">check-spf</strong></span>.
3742                 </p>
3743 </dd>
3744 <dt><span class="term"><span><strong class="command">check-mx-cname</strong></span></span></dt>
3745 <dd><p>
3746                   If <span><strong class="command">check-integrity</strong></span> is set then
3747                   fail, warn or ignore MX records that refer
3748                   to CNAMES.  The default is to <span><strong class="command">warn</strong></span>.
3749                 </p></dd>
3750 <dt><span class="term"><span><strong class="command">check-srv-cname</strong></span></span></dt>
3751 <dd><p>
3752                   If <span><strong class="command">check-integrity</strong></span> is set then
3753                   fail, warn or ignore SRV records that refer
3754                   to CNAMES.  The default is to <span><strong class="command">warn</strong></span>.
3755                 </p></dd>
3756 <dt><span class="term"><span><strong class="command">check-sibling</strong></span></span></dt>
3757 <dd><p>
3758                   When performing integrity checks, also check that
3759                   sibling glue exists.  The default is <span><strong class="command">yes</strong></span>.
3760                 </p></dd>
3761 <dt><span class="term"><span><strong class="command">check-spf</strong></span></span></dt>
3762 <dd><p>
3763                   If <span><strong class="command">check-integrity</strong></span> is set then
3764                   check that there is a TXT Sender Policy Framework
3765                   record present (starts with "v=spf1") if there is an
3766                   SPF record present. The default is
3767                   <span><strong class="command">warn</strong></span>.
3768                 </p></dd>
3769 <dt><span class="term"><span><strong class="command">zero-no-soa-ttl</strong></span></span></dt>
3770 <dd><p>
3771                   When returning authoritative negative responses to
3772                   SOA queries set the TTL of the SOA record returned in
3773                   the authority section to zero.
3774                   The default is <span><strong class="command">yes</strong></span>.
3775                 </p></dd>
3776 <dt><span class="term"><span><strong class="command">zero-no-soa-ttl-cache</strong></span></span></dt>
3777 <dd><p>
3778                   When caching a negative response to a SOA query
3779                   set the TTL to zero.
3780                   The default is <span><strong class="command">no</strong></span>.
3781                 </p></dd>
3782 <dt><span class="term"><span><strong class="command">update-check-ksk</strong></span></span></dt>
3783 <dd>
3784 <p>
3785                   When set to the default value of <code class="literal">yes</code>,
3786                   check the KSK bit in each key to determine how the key
3787                   should be used when generating RRSIGs for a secure zone.
3788                 </p>
3789 <p>
3790                   Ordinarily, zone-signing keys (that is, keys without the
3791                   KSK bit set) are used to sign the entire zone, while
3792                   key-signing keys (keys with the KSK bit set) are only
3793                   used to sign the DNSKEY RRset at the zone apex.
3794                   However, if this option is set to <code class="literal">no</code>,
3795                   then the KSK bit is ignored; KSKs are treated as if they
3796                   were ZSKs and are used to sign the entire zone.  This is
3797                   similar to the <span><strong class="command">dnssec-signzone -z</strong></span>
3798                   command line option.
3799                 </p>
3800 <p>
3801                   When this option is set to <code class="literal">yes</code>, there
3802                   must be at least two active keys for every algorithm
3803                   represented in the DNSKEY RRset: at least one KSK and one
3804                   ZSK per algorithm.  If there is any algorithm for which
3805                   this requirement is not met, this option will be ignored
3806                   for that algorithm.
3807                 </p>
3808 </dd>
3809 <dt><span class="term"><span><strong class="command">dnssec-dnskey-kskonly</strong></span></span></dt>
3810 <dd>
3811 <p>
3812                   When this option and <span><strong class="command">update-check-ksk</strong></span>
3813                   are both set to <code class="literal">yes</code>, only key-signing
3814                   keys (that is, keys with the KSK bit set) will be used
3815                   to sign the DNSKEY RRset at the zone apex.  Zone-signing
3816                   keys (keys without the KSK bit set) will be used to sign
3817                   the remainder of the zone, but not the DNSKEY RRset.
3818                   This is similar to the
3819                   <span><strong class="command">dnssec-signzone -x</strong></span> command line option.
3820                 </p>
3821 <p>
3822                   The default is <span><strong class="command">no</strong></span>.  If
3823                   <span><strong class="command">update-check-ksk</strong></span> is set to
3824                   <code class="literal">no</code>, this option is ignored.
3825                 </p>
3826 </dd>
3827 <dt><span class="term"><span><strong class="command">dnssec-loadkeys-interval</strong></span></span></dt>
3828 <dd><p>
3829                   When a zone is configured with <span><strong class="command">auto-dnssec
3830                   maintain;</strong></span> its key repository must be checked
3831                   periodically to see if any new keys have been added
3832                   or any existing keys' timing metadata has been updated
3833                   (see <a href="man.dnssec-keygen.html" title="dnssec-keygen"><span class="refentrytitle"><span class="application">dnssec-keygen</span></span>(8)</a> and
3834                   <a href="man.dnssec-settime.html" title="dnssec-settime"><span class="refentrytitle"><span class="application">dnssec-settime</span></span>(8)</a>).  The
3835                   <span><strong class="command">dnssec-loadkeys-interval</strong></span> option
3836                   sets the frequency of automatic repository checks, in
3837                   minutes.  The default is <code class="literal">60</code> (1 hour),
3838                   the minimum is <code class="literal">1</code> (1 minute), and the
3839                   maximum is <code class="literal">1440</code> (24 hours); any higher
3840                   value is silently reduced.
3841                 </p></dd>
3842 <dt><span class="term"><span><strong class="command">try-tcp-refresh</strong></span></span></dt>
3843 <dd><p>
3844                   Try to refresh the zone using TCP if UDP queries fail.
3845                   For BIND 8 compatibility, the default is
3846                   <span><strong class="command">yes</strong></span>.
3847                 </p></dd>
3848 <dt><span class="term"><span><strong class="command">dnssec-secure-to-insecure</strong></span></span></dt>
3849 <dd>
3850 <p>
3851                   Allow a dynamic zone to transition from secure to
3852                   insecure (i.e., signed to unsigned) by deleting all
3853                   of the DNSKEY records.  The default is <span><strong class="command">no</strong></span>.
3854                   If set to <span><strong class="command">yes</strong></span>, and if the DNSKEY RRset
3855                   at the zone apex is deleted, all RRSIG and NSEC records
3856                   will be removed from the zone as well.
3857                 </p>
3858 <p>
3859                   If the zone uses NSEC3, then it is also necessary to
3860                   delete the NSEC3PARAM RRset from the zone apex; this will
3861                   cause the removal of all corresponding NSEC3 records.
3862                   (It is expected that this requirement will be eliminated
3863                   in a future release.)
3864                 </p>
3865 <p>
3866                   Note that if a zone has been configured with
3867                   <span><strong class="command">auto-dnssec maintain</strong></span> and the
3868                   private keys remain accessible in the key repository,
3869                   then the zone will be automatically signed again the
3870                   next time <span><strong class="command">named</strong></span> is started.
3871                 </p>
3872 </dd>
3873 </dl></div>
3874 </div>
3875 <div class="sect3" lang="en">
3876 <div class="titlepage"><div><div><h4 class="title">
3877 <a name="id2583443"></a>Forwarding</h4></div></div></div>
3878 <p>
3879             The forwarding facility can be used to create a large site-wide
3880             cache on a few servers, reducing traffic over links to external
3881             name servers. It can also be used to allow queries by servers that
3882             do not have direct access to the Internet, but wish to look up
3883             exterior
3884             names anyway. Forwarding occurs only on those queries for which
3885             the server is not authoritative and does not have the answer in
3886             its cache.
3887           </p>
3888 <div class="variablelist"><dl>
3889 <dt><span class="term"><span><strong class="command">forward</strong></span></span></dt>
3890 <dd><p>
3891                   This option is only meaningful if the
3892                   forwarders list is not empty. A value of <code class="varname">first</code>,
3893                   the default, causes the server to query the forwarders
3894                   first &#8212; and
3895                   if that doesn't answer the question, the server will then
3896                   look for
3897                   the answer itself. If <code class="varname">only</code> is
3898                   specified, the
3899                   server will only query the forwarders.
3900                 </p></dd>
3901 <dt><span class="term"><span><strong class="command">forwarders</strong></span></span></dt>
3902 <dd><p>
3903                   Specifies the IP addresses to be used
3904                   for forwarding. The default is the empty list (no
3905                   forwarding).
3906                 </p></dd>
3907 </dl></div>
3908 <p>
3909             Forwarding can also be configured on a per-domain basis, allowing
3910             for the global forwarding options to be overridden in a variety
3911             of ways. You can set particular domains to use different
3912             forwarders,
3913             or have a different <span><strong class="command">forward only/first</strong></span> behavior,
3914             or not forward at all, see <a href="Bv9ARM.ch06.html#zone_statement_grammar" title="zone
3915             Statement Grammar">the section called &#8220;<span><strong class="command">zone</strong></span>
3916             Statement Grammar&#8221;</a>.
3917           </p>
3918 </div>
3919 <div class="sect3" lang="en">
3920 <div class="titlepage"><div><div><h4 class="title">
3921 <a name="id2583570"></a>Dual-stack Servers</h4></div></div></div>
3922 <p>
3923             Dual-stack servers are used as servers of last resort to work
3924             around
3925             problems in reachability due the lack of support for either IPv4
3926             or IPv6
3927             on the host machine.
3928           </p>
3929 <div class="variablelist"><dl>
3930 <dt><span class="term"><span><strong class="command">dual-stack-servers</strong></span></span></dt>
3931 <dd><p>
3932                   Specifies host names or addresses of machines with access to
3933                   both IPv4 and IPv6 transports. If a hostname is used, the
3934                   server must be able
3935                   to resolve the name using only the transport it has.  If the
3936                   machine is dual
3937                   stacked, then the <span><strong class="command">dual-stack-servers</strong></span> have no effect unless
3938                   access to a transport has been disabled on the command line
3939                   (e.g. <span><strong class="command">named -4</strong></span>).
3940                 </p></dd>
3941 </dl></div>
3942 </div>
3943 <div class="sect3" lang="en">
3944 <div class="titlepage"><div><div><h4 class="title">
3945 <a name="access_control"></a>Access Control</h4></div></div></div>
3946 <p>
3947             Access to the server can be restricted based on the IP address
3948             of the requesting system. See <a href="Bv9ARM.ch06.html#address_match_lists" title="Address Match Lists">the section called &#8220;Address Match Lists&#8221;</a> for
3949             details on how to specify IP address lists.
3950           </p>
3951 <div class="variablelist"><dl>
3952 <dt><span class="term"><span><strong class="command">allow-notify</strong></span></span></dt>
3953 <dd><p>
3954                   Specifies which hosts are allowed to
3955                   notify this server, a slave, of zone changes in addition
3956                   to the zone masters.
3957                   <span><strong class="command">allow-notify</strong></span> may also be
3958                   specified in the
3959                   <span><strong class="command">zone</strong></span> statement, in which case
3960                   it overrides the
3961                   <span><strong class="command">options allow-notify</strong></span>
3962                   statement.  It is only meaningful
3963                   for a slave zone.  If not specified, the default is to
3964                   process notify messages
3965                   only from a zone's master.
3966                 </p></dd>
3967 <dt><span class="term"><span><strong class="command">allow-query</strong></span></span></dt>
3968 <dd>
3969 <p>
3970                   Specifies which hosts are allowed to ask ordinary
3971                   DNS questions. <span><strong class="command">allow-query</strong></span> may
3972                   also be specified in the <span><strong class="command">zone</strong></span>
3973                   statement, in which case it overrides the
3974                   <span><strong class="command">options allow-query</strong></span> statement.
3975                   If not specified, the default is to allow queries
3976                   from all hosts.
3977                 </p>
3978 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
3979 <h3 class="title">Note</h3>
3980 <p>
3981                     <span><strong class="command">allow-query-cache</strong></span> is now
3982                     used to specify access to the cache.
3983                   </p>
3984 </div>
3985 </dd>
3986 <dt><span class="term"><span><strong class="command">allow-query-on</strong></span></span></dt>
3987 <dd>
3988 <p>
3989                   Specifies which local addresses can accept ordinary
3990                   DNS questions. This makes it possible, for instance,
3991                   to allow queries on internal-facing interfaces but
3992                   disallow them on external-facing ones, without
3993                   necessarily knowing the internal network's addresses.
3994                 </p>
3995 <p>
3996                   Note that <span><strong class="command">allow-query-on</strong></span> is only
3997                   checked for queries that are permitted by
3998                   <span><strong class="command">allow-query</strong></span>.  A query must be
3999                   allowed by both ACLs, or it will be refused.
4000                 </p>
4001 <p>
4002                   <span><strong class="command">allow-query-on</strong></span> may
4003                   also be specified in the <span><strong class="command">zone</strong></span>
4004                   statement, in which case it overrides the
4005                   <span><strong class="command">options allow-query-on</strong></span> statement.
4006                 </p>
4007 <p>
4008                   If not specified, the default is to allow queries
4009                   on all addresses.
4010                 </p>
4011 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4012 <h3 class="title">Note</h3>
4013 <p>
4014                     <span><strong class="command">allow-query-cache</strong></span> is
4015                     used to specify access to the cache.
4016                   </p>
4017 </div>
4018 </dd>
4019 <dt><span class="term"><span><strong class="command">allow-query-cache</strong></span></span></dt>
4020 <dd><p>
4021                   Specifies which hosts are allowed to get answers
4022                   from the cache.  If <span><strong class="command">allow-query-cache</strong></span>
4023                   is not set then <span><strong class="command">allow-recursion</strong></span>
4024                   is used if set, otherwise <span><strong class="command">allow-query</strong></span>
4025                   is used if set unless <span><strong class="command">recursion no;</strong></span> is
4026                   set in which case <span><strong class="command">none;</strong></span> is used,
4027                   otherwise the default (<span><strong class="command">localnets;</strong></span>
4028                   <span><strong class="command">localhost;</strong></span>) is used.
4029                 </p></dd>
4030 <dt><span class="term"><span><strong class="command">allow-query-cache-on</strong></span></span></dt>
4031 <dd><p>
4032                   Specifies which local addresses can give answers
4033                   from the cache.  If not specified, the default is
4034                   to allow cache queries on any address,
4035                   <span><strong class="command">localnets</strong></span> and
4036                   <span><strong class="command">localhost</strong></span>.
4037                 </p></dd>
4038 <dt><span class="term"><span><strong class="command">allow-recursion</strong></span></span></dt>
4039 <dd><p>
4040                   Specifies which hosts are allowed to make recursive
4041                   queries through this server. If
4042                   <span><strong class="command">allow-recursion</strong></span> is not set
4043                   then <span><strong class="command">allow-query-cache</strong></span> is
4044                   used if set, otherwise <span><strong class="command">allow-query</strong></span>
4045                   is used if set, otherwise the default
4046                   (<span><strong class="command">localnets;</strong></span>
4047                   <span><strong class="command">localhost;</strong></span>) is used.
4048                 </p></dd>
4049 <dt><span class="term"><span><strong class="command">allow-recursion-on</strong></span></span></dt>
4050 <dd><p>
4051                   Specifies which local addresses can accept recursive
4052                   queries.  If not specified, the default is to allow
4053                   recursive queries on all addresses.
4054                 </p></dd>
4055 <dt><span class="term"><span><strong class="command">allow-update</strong></span></span></dt>
4056 <dd><p>
4057                   Specifies which hosts are allowed to
4058                   submit Dynamic DNS updates for master zones. The default is
4059                   to deny
4060                   updates from all hosts.  Note that allowing updates based
4061                   on the requestor's IP address is insecure; see
4062                   <a href="Bv9ARM.ch07.html#dynamic_update_security" title="Dynamic Update Security">the section called &#8220;Dynamic Update Security&#8221;</a> for details.
4063                 </p></dd>
4064 <dt><span class="term"><span><strong class="command">allow-update-forwarding</strong></span></span></dt>
4065 <dd>
4066 <p>
4067                   Specifies which hosts are allowed to
4068                   submit Dynamic DNS updates to slave zones to be forwarded to
4069                   the
4070                   master.  The default is <strong class="userinput"><code>{ none; }</code></strong>,
4071                   which
4072                   means that no update forwarding will be performed.  To
4073                   enable
4074                   update forwarding, specify
4075                   <strong class="userinput"><code>allow-update-forwarding { any; };</code></strong>.
4076                   Specifying values other than <strong class="userinput"><code>{ none; }</code></strong> or
4077                   <strong class="userinput"><code>{ any; }</code></strong> is usually
4078                   counterproductive, since
4079                   the responsibility for update access control should rest
4080                   with the
4081                   master server, not the slaves.
4082                 </p>
4083 <p>
4084                   Note that enabling the update forwarding feature on a slave
4085                   server
4086                   may expose master servers relying on insecure IP address
4087                   based
4088                   access control to attacks; see <a href="Bv9ARM.ch07.html#dynamic_update_security" title="Dynamic Update Security">the section called &#8220;Dynamic Update Security&#8221;</a>
4089                   for more details.
4090                 </p>
4091 </dd>
4092 <dt><span class="term"><span><strong class="command">allow-v6-synthesis</strong></span></span></dt>
4093 <dd><p>
4094                   This option was introduced for the smooth transition from
4095                   AAAA
4096                   to A6 and from "nibble labels" to binary labels.
4097                   However, since both A6 and binary labels were then
4098                   deprecated,
4099                   this option was also deprecated.
4100                   It is now ignored with some warning messages.
4101                 </p></dd>
4102 <dt><span class="term"><span><strong class="command">allow-transfer</strong></span></span></dt>
4103 <dd><p>
4104                   Specifies which hosts are allowed to
4105                   receive zone transfers from the server. <span><strong class="command">allow-transfer</strong></span> may
4106                   also be specified in the <span><strong class="command">zone</strong></span>
4107                   statement, in which
4108                   case it overrides the <span><strong class="command">options allow-transfer</strong></span> statement.
4109                   If not specified, the default is to allow transfers to all
4110                   hosts.
4111                 </p></dd>
4112 <dt><span class="term"><span><strong class="command">blackhole</strong></span></span></dt>
4113 <dd><p>
4114                   Specifies a list of addresses that the
4115                   server will not accept queries from or use to resolve a
4116                   query. Queries
4117                   from these addresses will not be responded to. The default
4118                   is <strong class="userinput"><code>none</code></strong>.
4119                 </p></dd>
4120 <dt><span class="term"><span><strong class="command">filter-aaaa</strong></span></span></dt>
4121 <dd><p>
4122                   Specifies a list of addresses to which
4123                   <span><strong class="command">filter-aaaa-on-v4</strong></span>
4124                   is applies.  The default is <strong class="userinput"><code>any</code></strong>.
4125                 </p></dd>
4126 <dt><span class="term"><span><strong class="command">no-case-compress</strong></span></span></dt>
4127 <dd>
4128 <p>
4129                   Specifies a list of addresses which require responses
4130                   to use case-insensitive compression.  This ACL can be
4131                   used when <span><strong class="command">named</strong></span> needs to work with
4132                   clients that do not comply with the requirement in RFC
4133                   1034 to use case-insensitive name comparisons when
4134                   checking for matching domain names.
4135                 </p>
4136 <p>
4137                   If left undefined, the ACL defaults to
4138                   <span><strong class="command">none</strong></span>: case-insensitive compression
4139                   will be used for all clients.  If the ACL is defined and
4140                   matches a client, then case will be ignored when
4141                   compressing domain names in DNS responses sent to that
4142                   client.
4143                 </p>
4144 <p>
4145                   This can result in slightly smaller responses: if
4146                   a response contains the names "example.com" and
4147                   "example.COM", case-insensitive compression would treat
4148                   the second one as a duplicate.  It also ensures
4149                   that the case of the query name exactly matches the
4150                   case of the owner names of returned records, rather
4151                   than matching the case of the records entered in
4152                   the zone file.  This allows responses to exactly
4153                   match the query, which is required by some clients
4154                   due to incorrect use of case-sensitive comparisons.
4155                 </p>
4156 <p>
4157                   Case-insensitive compression is <span class="emphasis"><em>always</em></span>
4158                   used in AXFR and IXFR responses, regardless of whether
4159                   the client matches this ACL.
4160                 </p>
4161 <p>
4162                   There are circumstances in which <span><strong class="command">named</strong></span>
4163                   will not preserve the case of owner names of records:
4164                   if a zone file defines records of different types with
4165                   the same name, but the capitalization of the name is
4166                   different (e.g., "www.example.com/A" and
4167                   "WWW.EXAMPLE.COM/AAAA"), then all responses for that
4168                   name will use the <span class="emphasis"><em>first</em></span> version
4169                   of the name that was used in the zone file.  This
4170                   limitation may be addressed in a future release.  However,
4171                   domain names specified in the rdata of resource records
4172                   (i.e., records of type NS, MX, CNAME, etc) will always
4173                   have their case preserved unless the client matches this
4174                   ACL.
4175                 </p>
4176 </dd>
4177 <dt><span class="term"><span><strong class="command">resolver-query-timeout</strong></span></span></dt>
4178 <dd><p>
4179                   The amount of time the resolver will spend attempting
4180                   to resolve a recursive query before failing.  The default
4181                   and minimum is <code class="literal">10</code> and the maximum is
4182                   <code class="literal">30</code>.  Setting it to <code class="literal">0</code>
4183                   will result in the default being used.
4184                 </p></dd>
4185 </dl></div>
4186 </div>
4187 <div class="sect3" lang="en">
4188 <div class="titlepage"><div><div><h4 class="title">
4189 <a name="id2584312"></a>Interfaces</h4></div></div></div>
4190 <p>
4191             The interfaces and ports that the server will answer queries
4192             from may be specified using the <span><strong class="command">listen-on</strong></span> option. <span><strong class="command">listen-on</strong></span> takes
4193             an optional port and an <code class="varname">address_match_list</code>
4194             of IPv4 addresses.  (IPv6 addresses are ignored, with a
4195             logged warning.)
4196             The server will listen on all interfaces allowed by the address
4197             match list. If a port is not specified, port 53 will be used.
4198           </p>
4199 <p>
4200             Multiple <span><strong class="command">listen-on</strong></span> statements are
4201             allowed.
4202             For example,
4203           </p>
4204 <pre class="programlisting">listen-on { 5.6.7.8; };
4205 listen-on port 1234 { !1.2.3.4; 1.2/16; };
4206 </pre>
4207 <p>
4208             will enable the name server on port 53 for the IP address
4209             5.6.7.8, and on port 1234 of an address on the machine in net
4210             1.2 that is not 1.2.3.4.
4211           </p>
4212 <p>
4213             If no <span><strong class="command">listen-on</strong></span> is specified, the
4214             server will listen on port 53 on all IPv4 interfaces.
4215           </p>
4216 <p>
4217             The <span><strong class="command">listen-on-v6</strong></span> option is used to
4218             specify the interfaces and the ports on which the server will
4219             listen
4220             for incoming queries sent using IPv6.
4221           </p>
4222 <p>
4223             When </p>
4224 <pre class="programlisting">{ any; }</pre>
4225 <p> is
4226             specified
4227             as the <code class="varname">address_match_list</code> for the
4228             <span><strong class="command">listen-on-v6</strong></span> option,
4229             the server does not bind a separate socket to each IPv6 interface
4230             address as it does for IPv4 if the operating system has enough API
4231             support for IPv6 (specifically if it conforms to RFC 3493 and RFC
4232             3542).
4233             Instead, it listens on the IPv6 wildcard address.
4234             If the system only has incomplete API support for IPv6, however,
4235             the behavior is the same as that for IPv4.
4236           </p>
4237 <p>
4238             A list of particular IPv6 addresses can also be specified, in
4239             which case
4240             the server listens on a separate socket for each specified
4241             address,
4242             regardless of whether the desired API is supported by the system.
4243             IPv4 addresses specified in <span><strong class="command">listen-on-v6</strong></span>
4244             will be ignored, with a logged warning.
4245           </p>
4246 <p>
4247             Multiple <span><strong class="command">listen-on-v6</strong></span> options can
4248             be used.
4249             For example,
4250           </p>
4251 <pre class="programlisting">listen-on-v6 { any; };
4252 listen-on-v6 port 1234 { !2001:db8::/32; any; };
4253 </pre>
4254 <p>
4255             will enable the name server on port 53 for any IPv6 addresses
4256             (with a single wildcard socket),
4257             and on port 1234 of IPv6 addresses that is not in the prefix
4258             2001:db8::/32 (with separate sockets for each matched address.)
4259           </p>
4260 <p>
4261             To make the server not listen on any IPv6 address, use
4262           </p>
4263 <pre class="programlisting">listen-on-v6 { none; };
4264 </pre>
4265 <p>
4266             If no <span><strong class="command">listen-on-v6</strong></span> option is
4267             specified, the server will not listen on any IPv6 address
4268             unless <span><strong class="command">-6</strong></span> is specified when <span><strong class="command">named</strong></span> is
4269             invoked.  If <span><strong class="command">-6</strong></span> is specified then
4270             <span><strong class="command">named</strong></span> will listen on port 53 on all IPv6 interfaces by default.
4271           </p>
4272 </div>
4273 <div class="sect3" lang="en">
4274 <div class="titlepage"><div><div><h4 class="title">
4275 <a name="query_address"></a>Query Address</h4></div></div></div>
4276 <p>
4277             If the server doesn't know the answer to a question, it will
4278             query other name servers. <span><strong class="command">query-source</strong></span> specifies
4279             the address and port used for such queries. For queries sent over
4280             IPv6, there is a separate <span><strong class="command">query-source-v6</strong></span> option.
4281             If <span><strong class="command">address</strong></span> is <span><strong class="command">*</strong></span> (asterisk) or is omitted,
4282             a wildcard IP address (<span><strong class="command">INADDR_ANY</strong></span>)
4283             will be used.
4284           </p>
4285 <p>
4286             If <span><strong class="command">port</strong></span> is <span><strong class="command">*</strong></span> or is omitted,
4287             a random port number from a pre-configured
4288             range is picked up and will be used for each query.
4289             The port range(s) is that specified in
4290             the <span><strong class="command">use-v4-udp-ports</strong></span> (for IPv4)
4291             and <span><strong class="command">use-v6-udp-ports</strong></span> (for IPv6)
4292             options, excluding the ranges specified in
4293             the <span><strong class="command">avoid-v4-udp-ports</strong></span>
4294             and <span><strong class="command">avoid-v6-udp-ports</strong></span> options, respectively.
4295           </p>
4296 <p>
4297             The defaults of the <span><strong class="command">query-source</strong></span> and
4298             <span><strong class="command">query-source-v6</strong></span> options
4299             are:
4300           </p>
4301 <pre class="programlisting">query-source address * port *;
4302 query-source-v6 address * port *;
4303 </pre>
4304 <p>
4305             If <span><strong class="command">use-v4-udp-ports</strong></span> or
4306             <span><strong class="command">use-v6-udp-ports</strong></span> is unspecified,
4307             <span><strong class="command">named</strong></span> will check if the operating
4308             system provides a programming interface to retrieve the
4309             system's default range for ephemeral ports.
4310             If such an interface is available,
4311             <span><strong class="command">named</strong></span> will use the corresponding system
4312             default range; otherwise, it will use its own defaults:
4313          </p>
4314 <pre class="programlisting">use-v4-udp-ports { range 1024 65535; };
4315 use-v6-udp-ports { range 1024 65535; };
4316 </pre>
4317 <p>
4318             Note: make sure the ranges be sufficiently large for
4319             security.  A desirable size depends on various parameters,
4320             but we generally recommend it contain at least 16384 ports
4321             (14 bits of entropy).
4322             Note also that the system's default range when used may be
4323             too small for this purpose, and that the range may even be
4324             changed while <span><strong class="command">named</strong></span> is running; the new
4325             range will automatically be applied when <span><strong class="command">named</strong></span>
4326             is reloaded.
4327             It is encouraged to
4328             configure <span><strong class="command">use-v4-udp-ports</strong></span> and
4329             <span><strong class="command">use-v6-udp-ports</strong></span> explicitly so that the
4330             ranges are sufficiently large and are reasonably
4331             independent from the ranges used by other applications.
4332           </p>
4333 <p>
4334             Note: the operational configuration
4335             where <span><strong class="command">named</strong></span> runs may prohibit the use
4336             of some ports.  For example, UNIX systems will not allow
4337             <span><strong class="command">named</strong></span> running without a root privilege
4338             to use ports less than 1024.
4339             If such ports are included in the specified (or detected)
4340             set of query ports, the corresponding query attempts will
4341             fail, resulting in resolution failures or delay.
4342             It is therefore important to configure the set of ports
4343             that can be safely used in the expected operational environment.
4344           </p>
4345 <p>
4346             The defaults of the <span><strong class="command">avoid-v4-udp-ports</strong></span> and
4347             <span><strong class="command">avoid-v6-udp-ports</strong></span> options
4348             are:
4349           </p>
4350 <pre class="programlisting">avoid-v4-udp-ports {};
4351 avoid-v6-udp-ports {};
4352 </pre>
4353 <p>
4354             Note: BIND 9.5.0 introduced
4355             the <span><strong class="command">use-queryport-pool</strong></span> 
4356             option to support a pool of such random ports, but this
4357             option is now obsolete because reusing the same ports in
4358             the pool may not be sufficiently secure.
4359             For the same reason, it is generally strongly discouraged to
4360             specify a particular port for the
4361             <span><strong class="command">query-source</strong></span> or
4362             <span><strong class="command">query-source-v6</strong></span> options;
4363             it implicitly disables the use of randomized port numbers.
4364           </p>
4365 <div class="variablelist"><dl>
4366 <dt><span class="term"><span><strong class="command">use-queryport-pool</strong></span></span></dt>
4367 <dd><p>
4368                   This option is obsolete.
4369                 </p></dd>
4370 <dt><span class="term"><span><strong class="command">queryport-pool-ports</strong></span></span></dt>
4371 <dd><p>
4372                   This option is obsolete.
4373                 </p></dd>
4374 <dt><span class="term"><span><strong class="command">queryport-pool-updateinterval</strong></span></span></dt>
4375 <dd><p>
4376                   This option is obsolete.
4377                 </p></dd>
4378 </dl></div>
4379 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4380 <h3 class="title">Note</h3>
4381 <p>
4382               The address specified in the <span><strong class="command">query-source</strong></span> option
4383               is used for both UDP and TCP queries, but the port applies only
4384               to UDP queries.  TCP queries always use a random
4385               unprivileged port.
4386             </p>
4387 </div>
4388 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4389 <h3 class="title">Note</h3>
4390 <p>
4391               Solaris 2.5.1 and earlier does not support setting the source
4392               address for TCP sockets.
4393             </p>
4394 </div>
4395 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4396 <h3 class="title">Note</h3>
4397 <p>
4398               See also <span><strong class="command">transfer-source</strong></span> and
4399               <span><strong class="command">notify-source</strong></span>.
4400             </p>
4401 </div>
4402 </div>
4403 <div class="sect3" lang="en">
4404 <div class="titlepage"><div><div><h4 class="title">
4405 <a name="zone_transfers"></a>Zone Transfers</h4></div></div></div>
4406 <p>
4407             <acronym class="acronym">BIND</acronym> has mechanisms in place to
4408             facilitate zone transfers
4409             and set limits on the amount of load that transfers place on the
4410             system. The following options apply to zone transfers.
4411           </p>
4412 <div class="variablelist"><dl>
4413 <dt><span class="term"><span><strong class="command">also-notify</strong></span></span></dt>
4414 <dd>
4415 <p>
4416                   Defines a global list of IP addresses of name servers
4417                   that are also sent NOTIFY messages whenever a fresh copy of
4418                   the
4419                   zone is loaded, in addition to the servers listed in the
4420                   zone's NS records.
4421                   This helps to ensure that copies of the zones will
4422                   quickly converge on stealth servers.
4423                   Optionally, a port may be specified with each
4424                   <span><strong class="command">also-notify</strong></span> address to send
4425                   the notify messages to a port other than the
4426                   default of 53.
4427                   An optional TSIG key can also be specified with each
4428                   address to cause the notify messages to be signed; this
4429                   can be useful when sending notifies to multiple views.
4430                   In place of explicit addresses, one or more named
4431                   <span><strong class="command">masters</strong></span> lists can be used.
4432                 </p>
4433 <p>
4434                   If an <span><strong class="command">also-notify</strong></span> list
4435                   is given in a <span><strong class="command">zone</strong></span> statement,
4436                   it will override
4437                   the <span><strong class="command">options also-notify</strong></span>
4438                   statement. When a <span><strong class="command">zone notify</strong></span>
4439                   statement
4440                   is set to <span><strong class="command">no</strong></span>, the IP
4441                   addresses in the global <span><strong class="command">also-notify</strong></span> list will
4442                   not be sent NOTIFY messages for that zone. The default is
4443                   the empty
4444                   list (no global notification list).
4445                 </p>
4446 </dd>
4447 <dt><span class="term"><span><strong class="command">max-transfer-time-in</strong></span></span></dt>
4448 <dd><p>
4449                   Inbound zone transfers running longer than
4450                   this many minutes will be terminated. The default is 120
4451                   minutes
4452                   (2 hours).  The maximum value is 28 days (40320 minutes).
4453                 </p></dd>
4454 <dt><span class="term"><span><strong class="command">max-transfer-idle-in</strong></span></span></dt>
4455 <dd><p>
4456                   Inbound zone transfers making no progress
4457                   in this many minutes will be terminated. The default is 60
4458                   minutes
4459                   (1 hour).  The maximum value is 28 days (40320 minutes).
4460                 </p></dd>
4461 <dt><span class="term"><span><strong class="command">max-transfer-time-out</strong></span></span></dt>
4462 <dd><p>
4463                   Outbound zone transfers running longer than
4464                   this many minutes will be terminated. The default is 120
4465                   minutes
4466                   (2 hours).  The maximum value is 28 days (40320 minutes).
4467                 </p></dd>
4468 <dt><span class="term"><span><strong class="command">max-transfer-idle-out</strong></span></span></dt>
4469 <dd><p>
4470                   Outbound zone transfers making no progress
4471                   in this many minutes will be terminated.  The default is 60
4472                   minutes (1
4473                   hour).  The maximum value is 28 days (40320 minutes).
4474                 </p></dd>
4475 <dt><span class="term"><span><strong class="command">serial-query-rate</strong></span></span></dt>
4476 <dd>
4477 <p>
4478                   Slave servers will periodically query master
4479                   servers to find out if zone serial numbers have
4480                   changed. Each such query uses a minute amount of
4481                   the slave server's network bandwidth.  To limit
4482                   the amount of bandwidth used, BIND 9 limits the
4483                   rate at which queries are sent.  The value of the
4484                   <span><strong class="command">serial-query-rate</strong></span> option, an
4485                   integer, is the maximum number of queries sent
4486                   per second.  The default is 20 per second.
4487                   The lowest possible rate is one per second; when set
4488                   to zero, it will be silently raised to one.
4489                 </p>
4490 <p>
4491                   In addition to controlling the rate SOA refresh
4492                   queries are issued at
4493                   <span><strong class="command">serial-query-rate</strong></span> also controls
4494                   the rate at which NOTIFY messages are sent from
4495                   both master and slave zones.
4496                 </p>
4497 </dd>
4498 <dt><span class="term"><span><strong class="command">serial-queries</strong></span></span></dt>
4499 <dd><p>
4500                   In BIND 8, the <span><strong class="command">serial-queries</strong></span>
4501                   option
4502                   set the maximum number of concurrent serial number queries
4503                   allowed to be outstanding at any given time.
4504                   BIND 9 does not limit the number of outstanding
4505                   serial queries and ignores the <span><strong class="command">serial-queries</strong></span> option.
4506                   Instead, it limits the rate at which the queries are sent
4507                   as defined using the <span><strong class="command">serial-query-rate</strong></span> option.
4508                 </p></dd>
4509 <dt><span class="term"><span><strong class="command">transfer-format</strong></span></span></dt>
4510 <dd><p>
4511                   Zone transfers can be sent using two different formats,
4512                   <span><strong class="command">one-answer</strong></span> and
4513                   <span><strong class="command">many-answers</strong></span>.
4514                   The <span><strong class="command">transfer-format</strong></span> option is used
4515                   on the master server to determine which format it sends.
4516                   <span><strong class="command">one-answer</strong></span> uses one DNS message per
4517                   resource record transferred.
4518                   <span><strong class="command">many-answers</strong></span> packs as many resource
4519                   records as possible into a message.
4520                   <span><strong class="command">many-answers</strong></span> is more efficient, but is
4521                   only supported by relatively new slave servers,
4522                   such as <acronym class="acronym">BIND</acronym> 9, <acronym class="acronym">BIND</acronym>
4523                   8.x and <acronym class="acronym">BIND</acronym> 4.9.5 onwards.
4524                   The <span><strong class="command">many-answers</strong></span> format is also supported by
4525                   recent Microsoft Windows nameservers.
4526                   The default is <span><strong class="command">many-answers</strong></span>.
4527                   <span><strong class="command">transfer-format</strong></span> may be overridden on a
4528                   per-server basis by using the <span><strong class="command">server</strong></span>
4529                   statement.
4530                 </p></dd>
4531 <dt><span class="term"><span><strong class="command">transfers-in</strong></span></span></dt>
4532 <dd><p>
4533                   The maximum number of inbound zone transfers
4534                   that can be running concurrently. The default value is <code class="literal">10</code>.
4535                   Increasing <span><strong class="command">transfers-in</strong></span> may
4536                   speed up the convergence
4537                   of slave zones, but it also may increase the load on the
4538                   local system.
4539                 </p></dd>
4540 <dt><span class="term"><span><strong class="command">transfers-out</strong></span></span></dt>
4541 <dd><p>
4542                   The maximum number of outbound zone transfers
4543                   that can be running concurrently. Zone transfer requests in
4544                   excess
4545                   of the limit will be refused. The default value is <code class="literal">10</code>.
4546                 </p></dd>
4547 <dt><span class="term"><span><strong class="command">transfers-per-ns</strong></span></span></dt>
4548 <dd><p>
4549                   The maximum number of inbound zone transfers
4550                   that can be concurrently transferring from a given remote
4551                   name server.
4552                   The default value is <code class="literal">2</code>.
4553                   Increasing <span><strong class="command">transfers-per-ns</strong></span>
4554                   may
4555                   speed up the convergence of slave zones, but it also may
4556                   increase
4557                   the load on the remote name server. <span><strong class="command">transfers-per-ns</strong></span> may
4558                   be overridden on a per-server basis by using the <span><strong class="command">transfers</strong></span> phrase
4559                   of the <span><strong class="command">server</strong></span> statement.
4560                 </p></dd>
4561 <dt><span class="term"><span><strong class="command">transfer-source</strong></span></span></dt>
4562 <dd>
4563 <p><span><strong class="command">transfer-source</strong></span>
4564                   determines which local address will be bound to IPv4
4565                   TCP connections used to fetch zones transferred
4566                   inbound by the server.  It also determines the
4567                   source IPv4 address, and optionally the UDP port,
4568                   used for the refresh queries and forwarded dynamic
4569                   updates.  If not set, it defaults to a system
4570                   controlled value which will usually be the address
4571                   of the interface "closest to" the remote end. This
4572                   address must appear in the remote end's
4573                   <span><strong class="command">allow-transfer</strong></span> option for the
4574                   zone being transferred, if one is specified. This
4575                   statement sets the
4576                   <span><strong class="command">transfer-source</strong></span> for all zones,
4577                   but can be overridden on a per-view or per-zone
4578                   basis by including a
4579                   <span><strong class="command">transfer-source</strong></span> statement within
4580                   the <span><strong class="command">view</strong></span> or
4581                   <span><strong class="command">zone</strong></span> block in the configuration
4582                   file.
4583                 </p>
4584 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4585 <h3 class="title">Note</h3>
4586 <p>
4587                     Solaris 2.5.1 and earlier does not support setting the
4588                     source address for TCP sockets.
4589                   </p>
4590 </div>
4591 </dd>
4592 <dt><span class="term"><span><strong class="command">transfer-source-v6</strong></span></span></dt>
4593 <dd><p>
4594                   The same as <span><strong class="command">transfer-source</strong></span>,
4595                   except zone transfers are performed using IPv6.
4596                 </p></dd>
4597 <dt><span class="term"><span><strong class="command">alt-transfer-source</strong></span></span></dt>
4598 <dd>
4599 <p>
4600                   An alternate transfer source if the one listed in
4601                   <span><strong class="command">transfer-source</strong></span> fails and
4602                   <span><strong class="command">use-alt-transfer-source</strong></span> is
4603                   set.
4604                 </p>
4605 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4606 <h3 class="title">Note</h3>
4607                   If you do not wish the alternate transfer source
4608                   to be used, you should set
4609                   <span><strong class="command">use-alt-transfer-source</strong></span>
4610                   appropriately and you should not depend upon
4611                   getting an answer back to the first refresh
4612                   query.
4613                 </div>
4614 </dd>
4615 <dt><span class="term"><span><strong class="command">alt-transfer-source-v6</strong></span></span></dt>
4616 <dd><p>
4617                   An alternate transfer source if the one listed in
4618                   <span><strong class="command">transfer-source-v6</strong></span> fails and
4619                   <span><strong class="command">use-alt-transfer-source</strong></span> is
4620                   set.
4621                 </p></dd>
4622 <dt><span class="term"><span><strong class="command">use-alt-transfer-source</strong></span></span></dt>
4623 <dd><p>
4624                   Use the alternate transfer sources or not.  If views are
4625                   specified this defaults to <span><strong class="command">no</strong></span>
4626                   otherwise it defaults to
4627                   <span><strong class="command">yes</strong></span> (for BIND 8
4628                   compatibility).
4629                 </p></dd>
4630 <dt><span class="term"><span><strong class="command">notify-source</strong></span></span></dt>
4631 <dd>
4632 <p><span><strong class="command">notify-source</strong></span>
4633                   determines which local source address, and
4634                   optionally UDP port, will be used to send NOTIFY
4635                   messages.  This address must appear in the slave
4636                   server's <span><strong class="command">masters</strong></span> zone clause or
4637                   in an <span><strong class="command">allow-notify</strong></span> clause.  This
4638                   statement sets the <span><strong class="command">notify-source</strong></span>
4639                   for all zones, but can be overridden on a per-zone or
4640                   per-view basis by including a
4641                   <span><strong class="command">notify-source</strong></span> statement within
4642                   the <span><strong class="command">zone</strong></span> or
4643                   <span><strong class="command">view</strong></span> block in the configuration
4644                   file.
4645                 </p>
4646 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4647 <h3 class="title">Note</h3>
4648 <p>
4649                     Solaris 2.5.1 and earlier does not support setting the
4650                     source address for TCP sockets.
4651                   </p>
4652 </div>
4653 </dd>
4654 <dt><span class="term"><span><strong class="command">notify-source-v6</strong></span></span></dt>
4655 <dd><p>
4656                   Like <span><strong class="command">notify-source</strong></span>,
4657                   but applies to notify messages sent to IPv6 addresses.
4658                 </p></dd>
4659 </dl></div>
4660 </div>
4661 <div class="sect3" lang="en">
4662 <div class="titlepage"><div><div><h4 class="title">
4663 <a name="id2585465"></a>UDP Port Lists</h4></div></div></div>
4664 <p>
4665             <span><strong class="command">use-v4-udp-ports</strong></span>,
4666             <span><strong class="command">avoid-v4-udp-ports</strong></span>,
4667             <span><strong class="command">use-v6-udp-ports</strong></span>, and
4668             <span><strong class="command">avoid-v6-udp-ports</strong></span>
4669             specify a list of IPv4 and IPv6 UDP ports that will be
4670             used or not used as source ports for UDP messages.
4671             See <a href="Bv9ARM.ch06.html#query_address" title="Query Address">the section called &#8220;Query Address&#8221;</a> about how the
4672             available ports are determined.
4673             For example, with the following configuration
4674           </p>
4675 <pre class="programlisting">
4676 use-v6-udp-ports { range 32768 65535; };
4677 avoid-v6-udp-ports { 40000; range 50000 60000; };
4678 </pre>
4679 <p>
4680              UDP ports of IPv6 messages sent
4681              from <span><strong class="command">named</strong></span> will be in one
4682              of the following ranges: 32768 to 39999, 40001 to 49999,
4683              and 60001 to 65535.
4684            </p>
4685 <p>
4686              <span><strong class="command">avoid-v4-udp-ports</strong></span> and
4687              <span><strong class="command">avoid-v6-udp-ports</strong></span> can be used
4688              to prevent <span><strong class="command">named</strong></span> from choosing as its random source port a
4689              port that is blocked by your firewall or a port that is
4690              used by other applications;
4691              if a query went out with a source port blocked by a
4692              firewall, the
4693              answer would not get by the firewall and the name server would
4694              have to query again.
4695              Note: the desired range can also be represented only with
4696              <span><strong class="command">use-v4-udp-ports</strong></span> and
4697              <span><strong class="command">use-v6-udp-ports</strong></span>, and the
4698              <span><strong class="command">avoid-</strong></span> options are redundant in that
4699              sense; they are provided for backward compatibility and
4700              to possibly simplify the port specification.
4701            </p>
4702 </div>
4703 <div class="sect3" lang="en">
4704 <div class="titlepage"><div><div><h4 class="title">
4705 <a name="id2585525"></a>Operating System Resource Limits</h4></div></div></div>
4706 <p>
4707             The server's usage of many system resources can be limited.
4708             Scaled values are allowed when specifying resource limits.  For
4709             example, <span><strong class="command">1G</strong></span> can be used instead of
4710             <span><strong class="command">1073741824</strong></span> to specify a limit of
4711             one
4712             gigabyte. <span><strong class="command">unlimited</strong></span> requests
4713             unlimited use, or the
4714             maximum available amount. <span><strong class="command">default</strong></span>
4715             uses the limit
4716             that was in force when the server was started. See the description
4717             of <span><strong class="command">size_spec</strong></span> in <a href="Bv9ARM.ch06.html#configuration_file_elements" title="Configuration File Elements">the section called &#8220;Configuration File Elements&#8221;</a>.
4718           </p>
4719 <p>
4720             The following options set operating system resource limits for
4721             the name server process.  Some operating systems don't support
4722             some or
4723             any of the limits. On such systems, a warning will be issued if
4724             the
4725             unsupported limit is used.
4726           </p>
4727 <div class="variablelist"><dl>
4728 <dt><span class="term"><span><strong class="command">coresize</strong></span></span></dt>
4729 <dd><p>
4730                   The maximum size of a core dump. The default
4731                   is <code class="literal">default</code>.
4732                 </p></dd>
4733 <dt><span class="term"><span><strong class="command">datasize</strong></span></span></dt>
4734 <dd><p>
4735                   The maximum amount of data memory the server
4736                   may use. The default is <code class="literal">default</code>.
4737                   This is a hard limit on server memory usage.
4738                   If the server attempts to allocate memory in excess of this
4739                   limit, the allocation will fail, which may in turn leave
4740                   the server unable to perform DNS service.  Therefore,
4741                   this option is rarely useful as a way of limiting the
4742                   amount of memory used by the server, but it can be used
4743                   to raise an operating system data size limit that is
4744                   too small by default.  If you wish to limit the amount
4745                   of memory used by the server, use the
4746                   <span><strong class="command">max-cache-size</strong></span> and
4747                   <span><strong class="command">recursive-clients</strong></span>
4748                   options instead.
4749                 </p></dd>
4750 <dt><span class="term"><span><strong class="command">files</strong></span></span></dt>
4751 <dd><p>
4752                   The maximum number of files the server
4753                   may have open concurrently. The default is <code class="literal">unlimited</code>.
4754                 </p></dd>
4755 <dt><span class="term"><span><strong class="command">stacksize</strong></span></span></dt>
4756 <dd><p>
4757                   The maximum amount of stack memory the server
4758                   may use. The default is <code class="literal">default</code>.
4759                 </p></dd>
4760 </dl></div>
4761 </div>
4762 <div class="sect3" lang="en">
4763 <div class="titlepage"><div><div><h4 class="title">
4764 <a name="server_resource_limits"></a>Server  Resource Limits</h4></div></div></div>
4765 <p>
4766             The following options set limits on the server's
4767             resource consumption that are enforced internally by the
4768             server rather than the operating system.
4769           </p>
4770 <div class="variablelist"><dl>
4771 <dt><span class="term"><span><strong class="command">max-ixfr-log-size</strong></span></span></dt>
4772 <dd><p>
4773                   This option is obsolete; it is accepted
4774                   and ignored for BIND 8 compatibility.  The option
4775                   <span><strong class="command">max-journal-size</strong></span> performs a
4776                   similar function in BIND 9.
4777                 </p></dd>
4778 <dt><span class="term"><span><strong class="command">max-journal-size</strong></span></span></dt>
4779 <dd><p>
4780                   Sets a maximum size for each journal file
4781                   (see <a href="Bv9ARM.ch04.html#journal" title="The journal file">the section called &#8220;The journal file&#8221;</a>).  When the journal file
4782                   approaches
4783                   the specified size, some of the oldest transactions in the
4784                   journal
4785                   will be automatically removed.  The largest permitted
4786                   value is 2 gigabytes. The default is
4787                   <code class="literal">unlimited</code>, which also
4788                   means 2 gigabytes.
4789                   This may also be set on a per-zone basis.
4790                 </p></dd>
4791 <dt><span class="term"><span><strong class="command">host-statistics-max</strong></span></span></dt>
4792 <dd><p>
4793                   In BIND 8, specifies the maximum number of host statistics
4794                   entries to be kept.
4795                   Not implemented in BIND 9.
4796                 </p></dd>
4797 <dt><span class="term"><span><strong class="command">recursive-clients</strong></span></span></dt>
4798 <dd><p>
4799                   The maximum number of simultaneous recursive lookups
4800                   the server will perform on behalf of clients.  The default
4801                   is
4802                   <code class="literal">1000</code>.  Because each recursing
4803                   client uses a fair
4804                   bit of memory, on the order of 20 kilobytes, the value of
4805                   the
4806                   <span><strong class="command">recursive-clients</strong></span> option may
4807                   have to be decreased
4808                   on hosts with limited memory.
4809                 </p></dd>
4810 <dt><span class="term"><span><strong class="command">tcp-clients</strong></span></span></dt>
4811 <dd><p>
4812                   The maximum number of simultaneous client TCP
4813                   connections that the server will accept.
4814                   The default is <code class="literal">100</code>.
4815                 </p></dd>
4816 <dt><span class="term"><span><strong class="command">reserved-sockets</strong></span></span></dt>
4817 <dd>
4818 <p>
4819                   The number of file descriptors reserved for TCP, stdio,
4820                   etc.  This needs to be big enough to cover the number of
4821                   interfaces <span><strong class="command">named</strong></span> listens on, <span><strong class="command">tcp-clients</strong></span> as well as
4822                   to provide room for outgoing TCP queries and incoming zone
4823                   transfers.  The default is <code class="literal">512</code>.
4824                   The minimum value is <code class="literal">128</code> and the
4825                   maximum value is <code class="literal">128</code> less than
4826                   maxsockets (-S).  This option may be removed in the future.
4827                 </p>
4828 <p>
4829                   This option has little effect on Windows.
4830                 </p>
4831 </dd>
4832 <dt><span class="term"><span><strong class="command">max-cache-size</strong></span></span></dt>
4833 <dd><p>
4834                   The maximum amount of memory to use for the
4835                   server's cache, in bytes.
4836                   When the amount of data in the cache
4837                   reaches this limit, the server will cause records to expire
4838                   prematurely based on an LRU based strategy so that
4839                   the limit is not exceeded.
4840                   A value of 0 is special, meaning that
4841                   records are purged from the cache only when their
4842                   TTLs expire.
4843                   Another special keyword <strong class="userinput"><code>unlimited</code></strong>
4844                   means the maximum value of 32-bit unsigned integers
4845                   (0xffffffff), which may not have the same effect as
4846                   0 on machines that support more than 32 bits of
4847                   memory space.
4848                   Any positive values less than 2MB will be ignored reset
4849                   to 2MB.
4850                   In a server with multiple views, the limit applies
4851                   separately to the cache of each view.
4852                   The default is 0.
4853                 </p></dd>
4854 <dt><span class="term"><span><strong class="command">tcp-listen-queue</strong></span></span></dt>
4855 <dd><p>
4856                   The listen queue depth.  The default and minimum is 10.
4857                   If the kernel supports the accept filter "dataready" this
4858                   also controls how
4859                   many TCP connections that will be queued in kernel space
4860                   waiting for
4861                   some data before being passed to accept.  Nonzero values
4862                   less than 10 will be silently raised. A value of 0 may also
4863                   be used; on most platforms this sets the listen queue 
4864                   length to a system-defined default value.
4865                 </p></dd>
4866 </dl></div>
4867 </div>
4868 <div class="sect3" lang="en">
4869 <div class="titlepage"><div><div><h4 class="title">
4870 <a name="id2585947"></a>Periodic Task Intervals</h4></div></div></div>
4871 <div class="variablelist"><dl>
4872 <dt><span class="term"><span><strong class="command">cleaning-interval</strong></span></span></dt>
4873 <dd><p>
4874                   This interval is effectively obsolete.  Previously,
4875                   the server would remove expired resource records
4876                   from the cache every <span><strong class="command">cleaning-interval</strong></span> minutes.
4877                   <acronym class="acronym">BIND</acronym> 9 now manages cache
4878                   memory in a more sophisticated manner and does not
4879                   rely on the periodic cleaning any more.
4880                   Specifying this option therefore has no effect on
4881                   the server's behavior.
4882                 </p></dd>
4883 <dt><span class="term"><span><strong class="command">heartbeat-interval</strong></span></span></dt>
4884 <dd><p>
4885                   The server will perform zone maintenance tasks
4886                   for all zones marked as <span><strong class="command">dialup</strong></span> whenever this
4887                   interval expires. The default is 60 minutes. Reasonable
4888                   values are up
4889                   to 1 day (1440 minutes).  The maximum value is 28 days
4890                   (40320 minutes).
4891                   If set to 0, no zone maintenance for these zones will occur.
4892                 </p></dd>
4893 <dt><span class="term"><span><strong class="command">interface-interval</strong></span></span></dt>
4894 <dd><p>
4895                   The server will scan the network interface list
4896                   every <span><strong class="command">interface-interval</strong></span>
4897                   minutes. The default
4898                   is 60 minutes. The maximum value is 28 days (40320 minutes).
4899                   If set to 0, interface scanning will only occur when
4900                   the configuration file is  loaded. After the scan, the
4901                   server will
4902                   begin listening for queries on any newly discovered
4903                   interfaces (provided they are allowed by the
4904                   <span><strong class="command">listen-on</strong></span> configuration), and
4905                   will
4906                   stop listening on interfaces that have gone away.
4907                 </p></dd>
4908 <dt><span class="term"><span><strong class="command">statistics-interval</strong></span></span></dt>
4909 <dd>
4910 <p>
4911                   Name server statistics will be logged
4912                   every <span><strong class="command">statistics-interval</strong></span>
4913                   minutes. The default is
4914                   60. The maximum value is 28 days (40320 minutes).
4915                   If set to 0, no statistics will be logged.
4916                   </p>
4917 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4918 <h3 class="title">Note</h3>
4919 <p>
4920                     Not yet implemented in
4921                     <acronym class="acronym">BIND</acronym> 9.
4922                   </p>
4923 </div>
4924 </dd>
4925 </dl></div>
4926 </div>
4927 <div class="sect3" lang="en">
4928 <div class="titlepage"><div><div><h4 class="title">
4929 <a name="topology"></a>Topology</h4></div></div></div>
4930 <p>
4931             All other things being equal, when the server chooses a name
4932             server
4933             to query from a list of name servers, it prefers the one that is
4934             topologically closest to itself. The <span><strong class="command">topology</strong></span> statement
4935             takes an <span><strong class="command">address_match_list</strong></span> and
4936             interprets it
4937             in a special way. Each top-level list element is assigned a
4938             distance.
4939             Non-negated elements get a distance based on their position in the
4940             list, where the closer the match is to the start of the list, the
4941             shorter the distance is between it and the server. A negated match
4942             will be assigned the maximum distance from the server. If there
4943             is no match, the address will get a distance which is further than
4944             any non-negated list element, and closer than any negated element.
4945             For example,
4946           </p>
4947 <pre class="programlisting">topology {
4948     10/8;
4949     !1.2.3/24;
4950     { 1.2/16; 3/8; };
4951 };</pre>
4952 <p>
4953             will prefer servers on network 10 the most, followed by hosts
4954             on network 1.2.0.0 (netmask 255.255.0.0) and network 3, with the
4955             exception of hosts on network 1.2.3 (netmask 255.255.255.0), which
4956             is preferred least of all.
4957           </p>
4958 <p>
4959             The default topology is
4960           </p>
4961 <pre class="programlisting">    topology { localhost; localnets; };
4962 </pre>
4963 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
4964 <h3 class="title">Note</h3>
4965 <p>
4966               The <span><strong class="command">topology</strong></span> option
4967               is not implemented in <acronym class="acronym">BIND</acronym> 9.
4968             </p>
4969 </div>
4970 </div>
4971 <div class="sect3" lang="en">
4972 <div class="titlepage"><div><div><h4 class="title">
4973 <a name="the_sortlist_statement"></a>The <span><strong class="command">sortlist</strong></span> Statement</h4></div></div></div>
4974 <p>
4975             The response to a DNS query may consist of multiple resource
4976             records (RRs) forming a resource records set (RRset).
4977             The name server will normally return the
4978             RRs within the RRset in an indeterminate order
4979             (but see the <span><strong class="command">rrset-order</strong></span>
4980             statement in <a href="Bv9ARM.ch06.html#rrset_ordering" title="RRset Ordering">the section called &#8220;RRset Ordering&#8221;</a>).
4981             The client resolver code should rearrange the RRs as appropriate,
4982             that is, using any addresses on the local net in preference to
4983             other addresses.
4984             However, not all resolvers can do this or are correctly
4985             configured.
4986             When a client is using a local server, the sorting can be performed
4987             in the server, based on the client's address. This only requires
4988             configuring the name servers, not all the clients.
4989           </p>
4990 <p>
4991             The <span><strong class="command">sortlist</strong></span> statement (see below)
4992             takes
4993             an <span><strong class="command">address_match_list</strong></span> and
4994             interprets it even
4995             more specifically than the <span><strong class="command">topology</strong></span>
4996             statement
4997             does (<a href="Bv9ARM.ch06.html#topology" title="Topology">the section called &#8220;Topology&#8221;</a>).
4998             Each top level statement in the <span><strong class="command">sortlist</strong></span> must
4999             itself be an explicit <span><strong class="command">address_match_list</strong></span> with
5000             one or two elements. The first element (which may be an IP
5001             address,
5002             an IP prefix, an ACL name or a nested <span><strong class="command">address_match_list</strong></span>)
5003             of each top level list is checked against the source address of
5004             the query until a match is found.
5005           </p>
5006 <p>
5007             Once the source address of the query has been matched, if
5008             the top level statement contains only one element, the actual
5009             primitive
5010             element that matched the source address is used to select the
5011             address
5012             in the response to move to the beginning of the response. If the
5013             statement is a list of two elements, then the second element is
5014             treated the same as the <span><strong class="command">address_match_list</strong></span> in
5015             a <span><strong class="command">topology</strong></span> statement. Each top
5016             level element
5017             is assigned a distance and the address in the response with the
5018             minimum
5019             distance is moved to the beginning of the response.
5020           </p>
5021 <p>
5022             In the following example, any queries received from any of
5023             the addresses of the host itself will get responses preferring
5024             addresses
5025             on any of the locally connected networks. Next most preferred are
5026             addresses
5027             on the 192.168.1/24 network, and after that either the
5028             192.168.2/24
5029             or
5030             192.168.3/24 network with no preference shown between these two
5031             networks. Queries received from a host on the 192.168.1/24 network
5032             will prefer other addresses on that network to the 192.168.2/24
5033             and
5034             192.168.3/24 networks. Queries received from a host on the
5035             192.168.4/24
5036             or the 192.168.5/24 network will only prefer other addresses on
5037             their directly connected networks.
5038           </p>
5039 <pre class="programlisting">sortlist {
5040     // IF the local host
5041     // THEN first fit on the following nets
5042     { localhost;
5043         { localnets;
5044             192.168.1/24;
5045             { 192.168.2/24; 192.168.3/24; }; }; };
5046     // IF on class C 192.168.1 THEN use .1, or .2 or .3
5047     { 192.168.1/24;
5048         { 192.168.1/24;
5049             { 192.168.2/24; 192.168.3/24; }; }; };
5050     // IF on class C 192.168.2 THEN use .2, or .1 or .3
5051     { 192.168.2/24;
5052         { 192.168.2/24;
5053             { 192.168.1/24; 192.168.3/24; }; }; };
5054     // IF on class C 192.168.3 THEN use .3, or .1 or .2
5055     { 192.168.3/24;
5056         { 192.168.3/24;
5057             { 192.168.1/24; 192.168.2/24; }; }; };
5058     // IF .4 or .5 THEN prefer that net
5059     { { 192.168.4/24; 192.168.5/24; };
5060     };
5061 };</pre>
5062 <p>
5063             The following example will give reasonable behavior for the
5064             local host and hosts on directly connected networks. It is similar
5065             to the behavior of the address sort in <acronym class="acronym">BIND</acronym> 4.9.x. Responses sent
5066             to queries from the local host will favor any of the directly
5067             connected
5068             networks. Responses sent to queries from any other hosts on a
5069             directly
5070             connected network will prefer addresses on that same network.
5071             Responses
5072             to other queries will not be sorted.
5073           </p>
5074 <pre class="programlisting">sortlist {
5075            { localhost; localnets; };
5076            { localnets; };
5077 };
5078 </pre>
5079 </div>
5080 <div class="sect3" lang="en">
5081 <div class="titlepage"><div><div><h4 class="title">
5082 <a name="rrset_ordering"></a>RRset Ordering</h4></div></div></div>
5083 <p>
5084             When multiple records are returned in an answer it may be
5085             useful to configure the order of the records placed into the
5086             response.
5087             The <span><strong class="command">rrset-order</strong></span> statement permits
5088             configuration
5089             of the ordering of the records in a multiple record response.
5090             See also the <span><strong class="command">sortlist</strong></span> statement,
5091             <a href="Bv9ARM.ch06.html#the_sortlist_statement" title="The sortlist Statement">the section called &#8220;The <span><strong class="command">sortlist</strong></span> Statement&#8221;</a>.
5092           </p>
5093 <p>
5094             An <span><strong class="command">order_spec</strong></span> is defined as
5095             follows:
5096           </p>
5097 <p>
5098             [<span class="optional">class <em class="replaceable"><code>class_name</code></em></span>]
5099             [<span class="optional">type <em class="replaceable"><code>type_name</code></em></span>]
5100             [<span class="optional">name <em class="replaceable"><code>"domain_name"</code></em></span>]
5101             order <em class="replaceable"><code>ordering</code></em>
5102           </p>
5103 <p>
5104             If no class is specified, the default is <span><strong class="command">ANY</strong></span>.
5105             If no type is specified, the default is <span><strong class="command">ANY</strong></span>.
5106             If no name is specified, the default is "<span><strong class="command">*</strong></span>" (asterisk).
5107           </p>
5108 <p>
5109             The legal values for <span><strong class="command">ordering</strong></span> are:
5110           </p>
5111 <div class="informaltable"><table border="1">
5112 <colgroup>
5113 <col>
5114 <col>
5115 </colgroup>
5116 <tbody>
5117 <tr>
5118 <td>
5119                     <p><span><strong class="command">fixed</strong></span></p>
5120                   </td>
5121 <td>
5122                     <p>
5123                       Records are returned in the order they
5124                       are defined in the zone file.
5125                     </p>
5126                   </td>
5127 </tr>
5128 <tr>
5129 <td>
5130                     <p><span><strong class="command">random</strong></span></p>
5131                   </td>
5132 <td>
5133                     <p>
5134                       Records are returned in some random order.
5135                     </p>
5136                   </td>
5137 </tr>
5138 <tr>
5139 <td>
5140                     <p><span><strong class="command">cyclic</strong></span></p>
5141                   </td>
5142 <td>
5143                     <p>
5144                       Records are returned in a cyclic round-robin order.
5145                     </p>
5146                     <p>
5147                       If <acronym class="acronym">BIND</acronym> is configured with the
5148                       "--enable-fixed-rrset" option at compile time, then
5149                       the initial ordering of the RRset will match the
5150                       one specified in the zone file.
5151                     </p>
5152                   </td>
5153 </tr>
5154 </tbody>
5155 </table></div>
5156 <p>
5157             For example:
5158           </p>
5159 <pre class="programlisting">rrset-order {
5160    class IN type A name "host.example.com" order random;
5161    order cyclic;
5162 };
5163 </pre>
5164 <p>
5165             will cause any responses for type A records in class IN that
5166             have "<code class="literal">host.example.com</code>" as a
5167             suffix, to always be returned
5168             in random order. All other records are returned in cyclic order.
5169           </p>
5170 <p>
5171             If multiple <span><strong class="command">rrset-order</strong></span> statements
5172             appear, they are not combined &#8212; the last one applies.
5173           </p>
5174 <p>
5175             By default, all records are returned in random order.
5176           </p>
5177 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
5178 <h3 class="title">Note</h3>
5179 <p>
5180               In this release of <acronym class="acronym">BIND</acronym> 9, the
5181               <span><strong class="command">rrset-order</strong></span> statement does not support
5182               "fixed" ordering by default.  Fixed ordering can be enabled
5183               at compile time by specifying "--enable-fixed-rrset" on
5184               the "configure" command line.
5185             </p>
5186 </div>
5187 </div>
5188 <div class="sect3" lang="en">
5189 <div class="titlepage"><div><div><h4 class="title">
5190 <a name="tuning"></a>Tuning</h4></div></div></div>
5191 <div class="variablelist"><dl>
5192 <dt><span class="term"><span><strong class="command">lame-ttl</strong></span></span></dt>
5193 <dd>
5194 <p>
5195                   Sets the number of seconds to cache a
5196                   lame server indication. 0 disables caching. (This is
5197                   <span class="bold"><strong>NOT</strong></span> recommended.)
5198                   The default is <code class="literal">600</code> (10 minutes) and the
5199                   maximum value is
5200                   <code class="literal">1800</code> (30 minutes).
5201                 </p>
5202 <p>
5203                   Lame-ttl also controls the amount of time DNSSEC
5204                   validation failures are cached.  There is a minimum
5205                   of 30 seconds applied to bad cache entries if the
5206                   lame-ttl is set to less than 30 seconds.
5207                 </p>
5208 </dd>
5209 <dt><span class="term"><span><strong class="command">max-ncache-ttl</strong></span></span></dt>
5210 <dd><p>
5211                   To reduce network traffic and increase performance,
5212                   the server stores negative answers. <span><strong class="command">max-ncache-ttl</strong></span> is
5213                   used to set a maximum retention time for these answers in
5214                   the server
5215                   in seconds. The default
5216                   <span><strong class="command">max-ncache-ttl</strong></span> is <code class="literal">10800</code> seconds (3 hours).
5217                   <span><strong class="command">max-ncache-ttl</strong></span> cannot exceed
5218                   7 days and will
5219                   be silently truncated to 7 days if set to a greater value.
5220                 </p></dd>
5221 <dt><span class="term"><span><strong class="command">max-cache-ttl</strong></span></span></dt>
5222 <dd><p>
5223                   Sets the maximum time for which the server will
5224                   cache ordinary (positive) answers. The default is
5225                   one week (7 days).
5226                   A value of zero may cause all queries to return
5227                   SERVFAIL, because of lost caches of intermediate
5228                   RRsets (such as NS and glue AAAA/A records) in the
5229                   resolution process.
5230                 </p></dd>
5231 <dt><span class="term"><span><strong class="command">min-roots</strong></span></span></dt>
5232 <dd>
5233 <p>
5234                   The minimum number of root servers that
5235                   is required for a request for the root servers to be
5236                   accepted. The default
5237                   is <strong class="userinput"><code>2</code></strong>.
5238                 </p>
5239 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
5240 <h3 class="title">Note</h3>
5241 <p>
5242                     Not implemented in <acronym class="acronym">BIND</acronym> 9.
5243                   </p>
5244 </div>
5245 </dd>
5246 <dt><span class="term"><span><strong class="command">sig-validity-interval</strong></span></span></dt>
5247 <dd>
5248 <p>
5249                   Specifies the number of days into the future when
5250                   DNSSEC signatures automatically generated as a
5251                   result of dynamic updates (<a href="Bv9ARM.ch04.html#dynamic_update" title="Dynamic Update">the section called &#8220;Dynamic Update&#8221;</a>) will expire.  There
5252                   is an optional second field which specifies how
5253                   long before expiry that the signatures will be
5254                   regenerated.  If not specified, the signatures will
5255                   be regenerated at 1/4 of base interval.  The second
5256                   field is specified in days if the base interval is
5257                   greater than 7 days otherwise it is specified in hours.
5258                   The default base interval is <code class="literal">30</code> days
5259                   giving a re-signing interval of 7 1/2 days.  The maximum
5260                   values are 10 years (3660 days).
5261                 </p>
5262 <p>
5263                   The signature inception time is unconditionally
5264                   set to one hour before the current time to allow
5265                   for a limited amount of clock skew.
5266                 </p>
5267 <p>
5268                   The <span><strong class="command">sig-validity-interval</strong></span>
5269                   should be, at least, several multiples of the SOA
5270                   expire interval to allow for reasonable interaction
5271                   between the various timer and expiry dates.
5272                 </p>
5273 </dd>
5274 <dt><span class="term"><span><strong class="command">sig-signing-nodes</strong></span></span></dt>
5275 <dd><p>
5276                   Specify the maximum number of nodes to be
5277                   examined in each quantum when signing a zone with
5278                   a new DNSKEY. The default is
5279                   <code class="literal">100</code>.
5280                 </p></dd>
5281 <dt><span class="term"><span><strong class="command">sig-signing-signatures</strong></span></span></dt>
5282 <dd><p>
5283                   Specify a threshold number of signatures that
5284                   will terminate processing a quantum when signing
5285                   a zone with a new DNSKEY.  The default is
5286                   <code class="literal">10</code>.
5287                 </p></dd>
5288 <dt><span class="term"><span><strong class="command">sig-signing-type</strong></span></span></dt>
5289 <dd>
5290 <p>
5291                   Specify a private RDATA type to be used when generating
5292                   signing state records.  The default is
5293                   <code class="literal">65534</code>.
5294                 </p>
5295 <p>
5296                   It is expected that this parameter may be removed
5297                   in a future version once there is a standard type.
5298                 </p>
5299 <p>
5300                   Signing state records are used to internally by
5301                   <span><strong class="command">named</strong></span> to track the current state of
5302                   a zone-signing process, i.e., whether it is still active
5303                   or has been completed.  The records can be inspected
5304                   using the command
5305                   <span><strong class="command">rndc signing -list <em class="replaceable"><code>zone</code></em></strong></span>.
5306                   Once <span><strong class="command">named</strong></span> has finished signing
5307                   a zone with a particular key, the signing state
5308                   record associated with that key can be removed from
5309                   the zone by running
5310                   <span><strong class="command">rndc signing -clear <em class="replaceable"><code>keyid/algorithm</code></em> <em class="replaceable"><code>zone</code></em></strong></span>.
5311                   To clear all of the completed signing state
5312                   records for a zone, use
5313                   <span><strong class="command">rndc signing -clear all <em class="replaceable"><code>zone</code></em></strong></span>.
5314                 </p>
5315 </dd>
5316 <dt>
5317 <span class="term"><span><strong class="command">min-refresh-time</strong></span>, </span><span class="term"><span><strong class="command">max-refresh-time</strong></span>, </span><span class="term"><span><strong class="command">min-retry-time</strong></span>, </span><span class="term"><span><strong class="command">max-retry-time</strong></span></span>
5318 </dt>
5319 <dd>
5320 <p>
5321                   These options control the server's behavior on refreshing a
5322                   zone
5323                   (querying for SOA changes) or retrying failed transfers.
5324                   Usually the SOA values for the zone are used, but these
5325                   values
5326                   are set by the master, giving slave server administrators
5327                   little
5328                   control over their contents.
5329                 </p>
5330 <p>
5331                   These options allow the administrator to set a minimum and
5332                   maximum
5333                   refresh and retry time either per-zone, per-view, or
5334                   globally.
5335                   These options are valid for slave and stub zones,
5336                   and clamp the SOA refresh and retry times to the specified
5337                   values.
5338                 </p>
5339 <p>
5340                   The following defaults apply.
5341                   <span><strong class="command">min-refresh-time</strong></span> 300 seconds,
5342                   <span><strong class="command">max-refresh-time</strong></span> 2419200 seconds
5343                   (4 weeks), <span><strong class="command">min-retry-time</strong></span> 500 seconds,
5344                   and <span><strong class="command">max-retry-time</strong></span> 1209600 seconds
5345                   (2 weeks).
5346                 </p>
5347 </dd>
5348 <dt><span class="term"><span><strong class="command">edns-udp-size</strong></span></span></dt>
5349 <dd>
5350 <p>
5351                   Sets the advertised EDNS UDP buffer size in bytes
5352                   to control the size of packets received.
5353                   Valid values are 512 to 4096 (values outside this range
5354                   will be silently adjusted).  The default value
5355                   is 4096.  The usual reason for setting
5356                   <span><strong class="command">edns-udp-size</strong></span> to a non-default
5357                   value is to get UDP answers to pass through broken
5358                   firewalls that block fragmented packets and/or
5359                   block UDP packets that are greater than 512 bytes.
5360                 </p>
5361 <p>
5362                   <span><strong class="command">named</strong></span> will fallback to using 512 bytes
5363                   if it get a series of timeout at the initial value.  512
5364                   bytes is not being offered to encourage sites to fix their
5365                   firewalls.  Small EDNS UDP sizes will result in the
5366                   excessive use of TCP.
5367                 </p>
5368 </dd>
5369 <dt><span class="term"><span><strong class="command">max-udp-size</strong></span></span></dt>
5370 <dd>
5371 <p>
5372                   Sets the maximum EDNS UDP message size
5373                   <span><strong class="command">named</strong></span> will send in bytes.
5374                   Valid values are 512 to 4096 (values outside this
5375                   range will be silently adjusted).  The default
5376                   value is 4096.  The usual reason for setting
5377                   <span><strong class="command">max-udp-size</strong></span> to a non-default
5378                   value is to get UDP answers to pass through broken
5379                   firewalls that block fragmented packets and/or
5380                   block UDP packets that are greater than 512 bytes.
5381                   This is independent of the advertised receive
5382                   buffer (<span><strong class="command">edns-udp-size</strong></span>).
5383                 </p>
5384 <p>
5385                   Setting this to a low value will encourage additional
5386                   TCP traffic to the nameserver.
5387                 </p>
5388 </dd>
5389 <dt><span class="term"><span><strong class="command">masterfile-format</strong></span></span></dt>
5390 <dd>
5391 <p>Specifies
5392                   the file format of zone files (see
5393                   <a href="Bv9ARM.ch06.html#zonefile_format" title="Additional File Formats">the section called &#8220;Additional File Formats&#8221;</a>).
5394                   The default value is <code class="constant">text</code>, which is the
5395                   standard textual representation, except for slave zones,
5396                   in which the default value is <code class="constant">raw</code>.
5397                   Files in other formats than <code class="constant">text</code> are
5398                   typically expected to be generated by the
5399                   <span><strong class="command">named-compilezone</strong></span> tool, or dumped by
5400                   <span><strong class="command">named</strong></span>.
5401                 </p>
5402 <p>
5403                   Note that when a zone file in a different format than
5404                   <code class="constant">text</code> is loaded, <span><strong class="command">named</strong></span>
5405                   may omit some of the checks which would be performed for a
5406                   file in the <code class="constant">text</code> format.  In particular,
5407                   <span><strong class="command">check-names</strong></span> checks do not apply
5408                   for the <code class="constant">raw</code> format.  This means
5409                   a zone file in the <code class="constant">raw</code> format
5410                   must be generated with the same check level as that
5411                   specified in the <span><strong class="command">named</strong></span> configuration
5412                   file.  This statement sets the
5413                   <span><strong class="command">masterfile-format</strong></span> for all zones,
5414                   but can be overridden on a per-zone or per-view basis
5415                   by including a <span><strong class="command">masterfile-format</strong></span>
5416                   statement within the <span><strong class="command">zone</strong></span> or
5417                   <span><strong class="command">view</strong></span> block in the configuration
5418                   file.
5419                 </p>
5420 </dd>
5421 <dt>
5422 <a name="clients-per-query"></a><span class="term"><span><strong class="command">clients-per-query</strong></span>, </span><span class="term"><span><strong class="command">max-clients-per-query</strong></span></span>
5423 </dt>
5424 <dd>
5425 <p>These set the
5426                   initial value (minimum) and maximum number of recursive
5427                   simultaneous clients for any given query
5428                   (&lt;qname,qtype,qclass&gt;) that the server will accept
5429                   before dropping additional clients.  <span><strong class="command">named</strong></span> will attempt to
5430                   self tune this value and changes will be logged.  The
5431                   default values are 10 and 100.
5432                 </p>
5433 <p>
5434                   This value should reflect how many queries come in for
5435                   a given name in the time it takes to resolve that name.
5436                   If the number of queries exceed this value, <span><strong class="command">named</strong></span> will
5437                   assume that it is dealing with a non-responsive zone
5438                   and will drop additional queries.  If it gets a response
5439                   after dropping queries, it will raise the estimate.  The
5440                   estimate will then be lowered in 20 minutes if it has
5441                   remained unchanged.
5442                 </p>
5443 <p>
5444                   If <span><strong class="command">clients-per-query</strong></span> is set to zero,
5445                   then there is no limit on the number of clients per query
5446                   and no queries will be dropped.
5447                 </p>
5448 <p>
5449                   If <span><strong class="command">max-clients-per-query</strong></span> is set to zero,
5450                   then there is no upper bound other than imposed by
5451                   <span><strong class="command">recursive-clients</strong></span>.
5452                 </p>
5453 </dd>
5454 <dt>
5455 <a name="max-recursion-depth"></a><span class="term"><span><strong class="command">max-recursion-depth</strong></span></span>
5456 </dt>
5457 <dd><p>
5458                   Sets the maximum number of levels of recursion
5459                   that are permitted at any one time while servicing
5460                   a recursive query. Resolving a name may require
5461                   looking up a name server address, which in turn
5462                   requires resolving another name, etc; if the number
5463                   of indirections exceeds this value, the recursive
5464                   query is terminated and returns SERVFAIL.  The
5465                   default is 7.
5466                 </p></dd>
5467 <dt>
5468 <a name="max-recursion-queries"></a><span class="term"><span><strong class="command">max-recursion-queries</strong></span></span>
5469 </dt>
5470 <dd><p>
5471                   Sets the maximum number of iterative queries that
5472                   may be sent while servicing a recursive query.
5473                   If more queries are sent, the recursive query
5474                   is terminated and returns SERVFAIL. Queries to
5475                   look up top level comains such as "com" and "net"
5476                   and the DNS root zone are exempt from this limitation.
5477                   The default is 50.
5478                 </p></dd>
5479 <dt><span class="term"><span><strong class="command">notify-delay</strong></span></span></dt>
5480 <dd>
5481 <p>
5482                   The delay, in seconds, between sending sets of notify
5483                   messages for a zone.  The default is five (5) seconds.
5484                 </p>
5485 <p>
5486                   The overall rate that NOTIFY messages are sent for all
5487                   zones is controlled by <span><strong class="command">serial-query-rate</strong></span>.
5488                 </p>
5489 </dd>
5490 <dt><span class="term"><span><strong class="command">max-rsa-exponent-size</strong></span></span></dt>
5491 <dd><p>
5492                   The maximum RSA exponent size, in bits, that will
5493                   be accepted when validating.  Valid values are 35
5494                   to 4096 bits.  The default zero (0) is also accepted
5495                   and is equivalent to 4096.
5496                 </p></dd>
5497 </dl></div>
5498 </div>
5499 <div class="sect3" lang="en">
5500 <div class="titlepage"><div><div><h4 class="title">
5501 <a name="builtin"></a>Built-in server information zones</h4></div></div></div>
5502 <p>
5503             The server provides some helpful diagnostic information
5504             through a number of built-in zones under the
5505             pseudo-top-level-domain <code class="literal">bind</code> in the
5506             <span><strong class="command">CHAOS</strong></span> class.  These zones are part
5507             of a
5508             built-in view (see <a href="Bv9ARM.ch06.html#view_statement_grammar" title="view Statement Grammar">the section called &#8220;<span><strong class="command">view</strong></span> Statement Grammar&#8221;</a>) of
5509             class
5510             <span><strong class="command">CHAOS</strong></span> which is separate from the
5511             default view of class <span><strong class="command">IN</strong></span>. Most global
5512             configuration options (<span><strong class="command">allow-query</strong></span>,
5513             etc) will apply to this view, but some are locally
5514             overridden: <span><strong class="command">notify</strong></span>,
5515             <span><strong class="command">recursion</strong></span> and
5516             <span><strong class="command">allow-new-zones</strong></span> are
5517             always set to <strong class="userinput"><code>no</code></strong>.
5518           </p>
5519 <p>
5520             If you need to disable these zones, use the options
5521             below, or hide the built-in <span><strong class="command">CHAOS</strong></span>
5522             view by
5523             defining an explicit view of class <span><strong class="command">CHAOS</strong></span>
5524             that matches all clients.
5525           </p>
5526 <div class="variablelist"><dl>
5527 <dt><span class="term"><span><strong class="command">version</strong></span></span></dt>
5528 <dd><p>
5529                   The version the server should report
5530                   via a query of the name <code class="literal">version.bind</code>
5531                   with type <span><strong class="command">TXT</strong></span>, class <span><strong class="command">CHAOS</strong></span>.
5532                   The default is the real version number of this server.
5533                   Specifying <span><strong class="command">version none</strong></span>
5534                   disables processing of the queries.
5535                 </p></dd>
5536 <dt><span class="term"><span><strong class="command">hostname</strong></span></span></dt>
5537 <dd><p>
5538                   The hostname the server should report via a query of
5539                   the name <code class="filename">hostname.bind</code>
5540                   with type <span><strong class="command">TXT</strong></span>, class <span><strong class="command">CHAOS</strong></span>.
5541                   This defaults to the hostname of the machine hosting the
5542                   name server as
5543                   found by the gethostname() function.  The primary purpose of such queries
5544                   is to
5545                   identify which of a group of anycast servers is actually
5546                   answering your queries.  Specifying <span><strong class="command">hostname none;</strong></span>
5547                   disables processing of the queries.
5548                 </p></dd>
5549 <dt><span class="term"><span><strong class="command">server-id</strong></span></span></dt>
5550 <dd><p>
5551                   The ID the server should report when receiving a Name
5552                   Server Identifier (NSID) query, or a query of the name
5553                   <code class="filename">ID.SERVER</code> with type
5554                   <span><strong class="command">TXT</strong></span>, class <span><strong class="command">CHAOS</strong></span>.
5555                   The primary purpose of such queries is to
5556                   identify which of a group of anycast servers is actually
5557                   answering your queries.  Specifying <span><strong class="command">server-id none;</strong></span>
5558                   disables processing of the queries.
5559                   Specifying <span><strong class="command">server-id hostname;</strong></span> will cause <span><strong class="command">named</strong></span> to
5560                   use the hostname as found by the gethostname() function.
5561                   The default <span><strong class="command">server-id</strong></span> is <span><strong class="command">none</strong></span>.
5562                 </p></dd>
5563 </dl></div>
5564 </div>
5565 <div class="sect3" lang="en">
5566 <div class="titlepage"><div><div><h4 class="title">
5567 <a name="empty"></a>Built-in Empty Zones</h4></div></div></div>
5568 <p>
5569             Named has some built-in empty zones (SOA and NS records only).
5570             These are for zones that should normally be answered locally
5571             and which queries should not be sent to the Internet's root
5572             servers.  The official servers which cover these namespaces
5573             return NXDOMAIN responses to these queries.  In particular,
5574             these cover the reverse namespaces for addresses from
5575             RFC 1918, RFC 4193, RFC 5737 and RFC 6598.  They also include the
5576             reverse namespace for IPv6 local address (locally assigned),
5577             IPv6 link local addresses, the IPv6 loopback address and the
5578             IPv6 unknown address.
5579           </p>
5580 <p>
5581             Named will attempt to determine if a built-in zone already exists
5582             or is active (covered by a forward-only forwarding declaration)
5583             and will not create an empty zone in that case.
5584           </p>
5585 <p>
5586             The current list of empty zones is:
5587             </p>
5588 <div class="itemizedlist"><ul type="disc">
5589 <li>10.IN-ADDR.ARPA</li>
5590 <li>16.172.IN-ADDR.ARPA</li>
5591 <li>17.172.IN-ADDR.ARPA</li>
5592 <li>18.172.IN-ADDR.ARPA</li>
5593 <li>19.172.IN-ADDR.ARPA</li>
5594 <li>20.172.IN-ADDR.ARPA</li>
5595 <li>21.172.IN-ADDR.ARPA</li>
5596 <li>22.172.IN-ADDR.ARPA</li>
5597 <li>23.172.IN-ADDR.ARPA</li>
5598 <li>24.172.IN-ADDR.ARPA</li>
5599 <li>25.172.IN-ADDR.ARPA</li>
5600 <li>26.172.IN-ADDR.ARPA</li>
5601 <li>27.172.IN-ADDR.ARPA</li>
5602 <li>28.172.IN-ADDR.ARPA</li>
5603 <li>29.172.IN-ADDR.ARPA</li>
5604 <li>30.172.IN-ADDR.ARPA</li>
5605 <li>31.172.IN-ADDR.ARPA</li>
5606 <li>168.192.IN-ADDR.ARPA</li>
5607 <li>64.100.IN-ADDR.ARPA</li>
5608 <li>65.100.IN-ADDR.ARPA</li>
5609 <li>66.100.IN-ADDR.ARPA</li>
5610 <li>67.100.IN-ADDR.ARPA</li>
5611 <li>68.100.IN-ADDR.ARPA</li>
5612 <li>69.100.IN-ADDR.ARPA</li>
5613 <li>70.100.IN-ADDR.ARPA</li>
5614 <li>71.100.IN-ADDR.ARPA</li>
5615 <li>72.100.IN-ADDR.ARPA</li>
5616 <li>73.100.IN-ADDR.ARPA</li>
5617 <li>74.100.IN-ADDR.ARPA</li>
5618 <li>75.100.IN-ADDR.ARPA</li>
5619 <li>76.100.IN-ADDR.ARPA</li>
5620 <li>77.100.IN-ADDR.ARPA</li>
5621 <li>78.100.IN-ADDR.ARPA</li>
5622 <li>79.100.IN-ADDR.ARPA</li>
5623 <li>80.100.IN-ADDR.ARPA</li>
5624 <li>81.100.IN-ADDR.ARPA</li>
5625 <li>82.100.IN-ADDR.ARPA</li>
5626 <li>83.100.IN-ADDR.ARPA</li>
5627 <li>84.100.IN-ADDR.ARPA</li>
5628 <li>85.100.IN-ADDR.ARPA</li>
5629 <li>86.100.IN-ADDR.ARPA</li>
5630 <li>87.100.IN-ADDR.ARPA</li>
5631 <li>88.100.IN-ADDR.ARPA</li>
5632 <li>89.100.IN-ADDR.ARPA</li>
5633 <li>90.100.IN-ADDR.ARPA</li>
5634 <li>91.100.IN-ADDR.ARPA</li>
5635 <li>92.100.IN-ADDR.ARPA</li>
5636 <li>93.100.IN-ADDR.ARPA</li>
5637 <li>94.100.IN-ADDR.ARPA</li>
5638 <li>95.100.IN-ADDR.ARPA</li>
5639 <li>96.100.IN-ADDR.ARPA</li>
5640 <li>97.100.IN-ADDR.ARPA</li>
5641 <li>98.100.IN-ADDR.ARPA</li>
5642 <li>99.100.IN-ADDR.ARPA</li>
5643 <li>100.100.IN-ADDR.ARPA</li>
5644 <li>101.100.IN-ADDR.ARPA</li>
5645 <li>102.100.IN-ADDR.ARPA</li>
5646 <li>103.100.IN-ADDR.ARPA</li>
5647 <li>104.100.IN-ADDR.ARPA</li>
5648 <li>105.100.IN-ADDR.ARPA</li>
5649 <li>106.100.IN-ADDR.ARPA</li>
5650 <li>107.100.IN-ADDR.ARPA</li>
5651 <li>108.100.IN-ADDR.ARPA</li>
5652 <li>109.100.IN-ADDR.ARPA</li>
5653 <li>110.100.IN-ADDR.ARPA</li>
5654 <li>111.100.IN-ADDR.ARPA</li>
5655 <li>112.100.IN-ADDR.ARPA</li>
5656 <li>113.100.IN-ADDR.ARPA</li>
5657 <li>114.100.IN-ADDR.ARPA</li>
5658 <li>115.100.IN-ADDR.ARPA</li>
5659 <li>116.100.IN-ADDR.ARPA</li>
5660 <li>117.100.IN-ADDR.ARPA</li>
5661 <li>118.100.IN-ADDR.ARPA</li>
5662 <li>119.100.IN-ADDR.ARPA</li>
5663 <li>120.100.IN-ADDR.ARPA</li>
5664 <li>121.100.IN-ADDR.ARPA</li>
5665 <li>122.100.IN-ADDR.ARPA</li>
5666 <li>123.100.IN-ADDR.ARPA</li>
5667 <li>124.100.IN-ADDR.ARPA</li>
5668 <li>125.100.IN-ADDR.ARPA</li>
5669 <li>126.100.IN-ADDR.ARPA</li>
5670 <li>127.100.IN-ADDR.ARPA</li>
5671 <li>0.IN-ADDR.ARPA</li>
5672 <li>127.IN-ADDR.ARPA</li>
5673 <li>254.169.IN-ADDR.ARPA</li>
5674 <li>2.0.192.IN-ADDR.ARPA</li>
5675 <li>100.51.198.IN-ADDR.ARPA</li>
5676 <li>113.0.203.IN-ADDR.ARPA</li>
5677 <li>255.255.255.255.IN-ADDR.ARPA</li>
5678 <li>0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA</li>
5679 <li>1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA</li>
5680 <li>8.B.D.0.1.0.0.2.IP6.ARPA</li>
5681 <li>D.F.IP6.ARPA</li>
5682 <li>8.E.F.IP6.ARPA</li>
5683 <li>9.E.F.IP6.ARPA</li>
5684 <li>A.E.F.IP6.ARPA</li>
5685 <li>B.E.F.IP6.ARPA</li>
5686 </ul></div>
5687 <p>
5688           </p>
5689 <p>
5690             Empty zones are settable at the view level and only apply to
5691             views of class IN.  Disabled empty zones are only inherited
5692             from options if there are no disabled empty zones specified
5693             at the view level.  To override the options list of disabled
5694             zones, you can disable the root zone at the view level, for example:
5695 </p>
5696 <pre class="programlisting">
5697             disable-empty-zone ".";
5698 </pre>
5699 <p>
5700           </p>
5701 <p>
5702             If you are using the address ranges covered here, you should
5703             already have reverse zones covering the addresses you use.
5704             In practice this appears to not be the case with many queries
5705             being made to the infrastructure servers for names in these
5706             spaces.  So many in fact that sacrificial servers were needed
5707             to be deployed to channel the query load away from the
5708             infrastructure servers.
5709           </p>
5710 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
5711 <h3 class="title">Note</h3>
5712             The real parent servers for these zones should disable all
5713             empty zone under the parent zone they serve.  For the real
5714             root servers, this is all built-in empty zones.  This will
5715             enable them to return referrals to deeper in the tree.
5716           </div>
5717 <div class="variablelist"><dl>
5718 <dt><span class="term"><span><strong class="command">empty-server</strong></span></span></dt>
5719 <dd><p>
5720                   Specify what server name will appear in the returned
5721                   SOA record for empty zones.  If none is specified, then
5722                   the zone's name will be used.
5723                 </p></dd>
5724 <dt><span class="term"><span><strong class="command">empty-contact</strong></span></span></dt>
5725 <dd><p>
5726                   Specify what contact name will appear in the returned
5727                   SOA record for empty zones.  If none is specified, then
5728                   "." will be used.
5729                 </p></dd>
5730 <dt><span class="term"><span><strong class="command">empty-zones-enable</strong></span></span></dt>
5731 <dd><p>
5732                   Enable or disable all empty zones.  By default, they
5733                   are enabled.
5734                 </p></dd>
5735 <dt><span class="term"><span><strong class="command">disable-empty-zone</strong></span></span></dt>
5736 <dd><p>
5737                   Disable individual empty zones.  By default, none are
5738                   disabled.  This option can be specified multiple times.
5739                 </p></dd>
5740 </dl></div>
5741 </div>
5742 <div class="sect3" lang="en">
5743 <div class="titlepage"><div><div><h4 class="title">
5744 <a name="acache"></a>Additional Section Caching</h4></div></div></div>
5745 <p>
5746             The additional section cache, also called <span><strong class="command">acache</strong></span>,
5747             is an internal cache to improve the response performance of BIND 9.
5748             When additional section caching is enabled, BIND 9 will
5749             cache an internal short-cut to the additional section content for
5750             each answer RR.
5751             Note that <span><strong class="command">acache</strong></span> is an internal caching
5752             mechanism of BIND 9, and is not related to the DNS caching
5753             server function.
5754           </p>
5755 <p>
5756             Additional section caching does not change the
5757             response content (except the RRsets ordering of the additional
5758             section, see below), but can improve the response performance
5759             significantly.
5760             It is particularly effective when BIND 9 acts as an authoritative
5761             server for a zone that has many delegations with many glue RRs.
5762           </p>
5763 <p>
5764             In order to obtain the maximum performance improvement
5765             from additional section caching, setting
5766             <span><strong class="command">additional-from-cache</strong></span>
5767             to <span><strong class="command">no</strong></span> is recommended, since the current
5768             implementation of <span><strong class="command">acache</strong></span>
5769             does not short-cut of additional section information from the
5770             DNS cache data.
5771           </p>
5772 <p>
5773             One obvious disadvantage of <span><strong class="command">acache</strong></span> is
5774             that it requires much more
5775             memory for the internal cached data.
5776             Thus, if the response performance does not matter and memory
5777             consumption is much more critical, the
5778             <span><strong class="command">acache</strong></span> mechanism can be
5779             disabled by setting <span><strong class="command">acache-enable</strong></span> to
5780             <span><strong class="command">no</strong></span>.
5781             It is also possible to specify the upper limit of memory
5782             consumption
5783             for acache by using <span><strong class="command">max-acache-size</strong></span>.
5784           </p>
5785 <p>
5786             Additional section caching also has a minor effect on the
5787             RRset ordering in the additional section.
5788             Without <span><strong class="command">acache</strong></span>,
5789             <span><strong class="command">cyclic</strong></span> order is effective for the additional
5790             section as well as the answer and authority sections.
5791             However, additional section caching fixes the ordering when it
5792             first caches an RRset for the additional section, and the same
5793             ordering will be kept in succeeding responses, regardless of the
5794             setting of <span><strong class="command">rrset-order</strong></span>.
5795             The effect of this should be minor, however, since an
5796             RRset in the additional section
5797             typically only contains a small number of RRs (and in many cases
5798             it only contains a single RR), in which case the
5799             ordering does not matter much.
5800           </p>
5801 <p>
5802             The following is a summary of options related to
5803             <span><strong class="command">acache</strong></span>.
5804           </p>
5805 <div class="variablelist"><dl>
5806 <dt><span class="term"><span><strong class="command">acache-enable</strong></span></span></dt>
5807 <dd><p>
5808                   If <span><strong class="command">yes</strong></span>, additional section caching is
5809                   enabled.  The default value is <span><strong class="command">no</strong></span>.
5810                 </p></dd>
5811 <dt><span class="term"><span><strong class="command">acache-cleaning-interval</strong></span></span></dt>
5812 <dd><p>
5813                   The server will remove stale cache entries, based on an LRU
5814                   based
5815                   algorithm, every <span><strong class="command">acache-cleaning-interval</strong></span> minutes.
5816                   The default is 60 minutes.
5817                   If set to 0, no periodic cleaning will occur.
5818                 </p></dd>
5819 <dt><span class="term"><span><strong class="command">max-acache-size</strong></span></span></dt>
5820 <dd><p>
5821                   The maximum amount of memory in bytes to use for the server's acache.
5822                   When the amount of data in the acache reaches this limit,
5823                   the server
5824                   will clean more aggressively so that the limit is not
5825                   exceeded.
5826                   In a server with multiple views, the limit applies
5827                   separately to the
5828                   acache of each view.
5829                   The default is <code class="literal">16M</code>.
5830                 </p></dd>
5831 </dl></div>
5832 </div>
5833 <div class="sect3" lang="en">
5834 <div class="titlepage"><div><div><h4 class="title">
5835 <a name="id2588571"></a>Content Filtering</h4></div></div></div>
5836 <p>
5837             <acronym class="acronym">BIND</acronym> 9 provides the ability to filter
5838             out DNS responses from external DNS servers containing
5839             certain types of data in the answer section.
5840             Specifically, it can reject address (A or AAAA) records if
5841             the corresponding IPv4 or IPv6 addresses match the given
5842             <code class="varname">address_match_list</code> of the
5843             <span><strong class="command">deny-answer-addresses</strong></span> option.
5844             It can also reject CNAME or DNAME records if the "alias"
5845             name (i.e., the CNAME alias or the substituted query name
5846             due to DNAME) matches the
5847             given <code class="varname">namelist</code> of the
5848             <span><strong class="command">deny-answer-aliases</strong></span> option, where
5849             "match" means the alias name is a subdomain of one of
5850             the <code class="varname">name_list</code> elements.
5851             If the optional <code class="varname">namelist</code> is specified
5852             with <span><strong class="command">except-from</strong></span>, records whose query name
5853             matches the list will be accepted regardless of the filter
5854             setting.
5855             Likewise, if the alias name is a subdomain of the
5856             corresponding zone, the <span><strong class="command">deny-answer-aliases</strong></span>
5857             filter will not apply;
5858             for example, even if "example.com" is specified for
5859             <span><strong class="command">deny-answer-aliases</strong></span>,
5860           </p>
5861 <pre class="programlisting">www.example.com. CNAME xxx.example.com.</pre>
5862 <p>
5863             returned by an "example.com" server will be accepted.
5864           </p>
5865 <p>
5866             In the <code class="varname">address_match_list</code> of the
5867             <span><strong class="command">deny-answer-addresses</strong></span> option, only
5868             <code class="varname">ip_addr</code>
5869             and <code class="varname">ip_prefix</code>
5870             are meaningful;
5871             any <code class="varname">key_id</code> will be silently ignored.
5872           </p>
5873 <p>
5874             If a response message is rejected due to the filtering,
5875             the entire message is discarded without being cached, and
5876             a SERVFAIL error will be returned to the client.
5877           </p>
5878 <p>
5879             This filtering is intended to prevent "DNS rebinding attacks," in
5880             which an attacker, in response to a query for a domain name the
5881             attacker controls, returns an IP address within your own network or
5882             an alias name within your own domain.
5883             A naive web browser or script could then serve as an
5884             unintended proxy, allowing the attacker
5885             to get access to an internal node of your local network
5886             that couldn't be externally accessed otherwise.
5887             See the paper available at
5888             <a href="http://portal.acm.org/citation.cfm?id=1315245.1315298" target="_top">
5889             http://portal.acm.org/citation.cfm?id=1315245.1315298
5890             </a>
5891             for more details about the attacks.
5892           </p>
5893 <p>
5894             For example, if you own a domain named "example.net" and
5895             your internal network uses an IPv4 prefix 192.0.2.0/24,
5896             you might specify the following rules:
5897           </p>
5898 <pre class="programlisting">deny-answer-addresses { 192.0.2.0/24; } except-from { "example.net"; };
5899 deny-answer-aliases { "example.net"; };
5900 </pre>
5901 <p>
5902             If an external attacker lets a web browser in your local
5903             network look up an IPv4 address of "attacker.example.com",
5904             the attacker's DNS server would return a response like this:
5905           </p>
5906 <pre class="programlisting">attacker.example.com. A 192.0.2.1</pre>
5907 <p>
5908             in the answer section.
5909             Since the rdata of this record (the IPv4 address) matches
5910             the specified prefix 192.0.2.0/24, this response will be
5911             ignored.
5912           </p>
5913 <p>
5914             On the other hand, if the browser looks up a legitimate
5915             internal web server "www.example.net" and the
5916             following response is returned to
5917             the <acronym class="acronym">BIND</acronym> 9 server
5918           </p>
5919 <pre class="programlisting">www.example.net. A 192.0.2.2</pre>
5920 <p>
5921             it will be accepted since the owner name "www.example.net"
5922             matches the <span><strong class="command">except-from</strong></span> element,
5923             "example.net".
5924           </p>
5925 <p>
5926             Note that this is not really an attack on the DNS per se.
5927             In fact, there is nothing wrong for an "external" name to
5928             be mapped to your "internal" IP address or domain name
5929             from the DNS point of view.
5930             It might actually be provided for a legitimate purpose,
5931             such as for debugging.
5932             As long as the mapping is provided by the correct owner,
5933             it is not possible or does not make sense to detect
5934             whether the intent of the mapping is legitimate or not
5935             within the DNS.
5936             The "rebinding" attack must primarily be protected at the
5937             application that uses the DNS.
5938             For a large site, however, it may be difficult to protect
5939             all possible applications at once.
5940             This filtering feature is provided only to help such an
5941             operational environment;
5942             it is generally discouraged to turn it on unless you are
5943             very sure you have no other choice and the attack is a
5944             real threat for your applications.
5945           </p>
5946 <p>
5947             Care should be particularly taken if you want to use this
5948             option for addresses within 127.0.0.0/8.
5949             These addresses are obviously "internal", but many
5950             applications conventionally rely on a DNS mapping from
5951             some name to such an address.
5952             Filtering out DNS records containing this address
5953             spuriously can break such applications.
5954           </p>
5955 </div>
5956 <div class="sect3" lang="en">
5957 <div class="titlepage"><div><div><h4 class="title">
5958 <a name="id2588765"></a>Response Policy Zone (RPZ) Rewriting</h4></div></div></div>
5959 <p>
5960             <acronym class="acronym">BIND</acronym> 9 includes a limited
5961             mechanism to modify DNS responses for requests
5962             analogous to email anti-spam DNS blacklists.
5963             Responses can be changed to deny the existence of domains (NXDOMAIN),
5964             deny the existence of IP addresses for domains (NODATA),
5965             or contain other IP addresses or data.
5966           </p>
5967 <p>
5968             Response policy zones are named in the
5969             <span><strong class="command">response-policy</strong></span> option for the view or among the
5970             global options if there is no response-policy option for the view.
5971             RPZs are ordinary DNS zones containing RRsets
5972             that can be queried normally if allowed.
5973             It is usually best to restrict those queries with something like
5974             <span><strong class="command">allow-query { localhost; };</strong></span>.
5975           </p>
5976 <p>
5977             Four policy triggers are encoded in RPZ records, QNAME, IP, NSIP,
5978             and NSDNAME.
5979             QNAME RPZ records triggered by query names of requests and targets
5980             of CNAME records resolved to generate the response.
5981             The owner name of a QNAME RPZ record is the query name relativized
5982             to the RPZ.
5983           </p>
5984 <p>
5985             The second kind of RPZ trigger is an IP address in an A and AAAA
5986             record in the ANSWER section of a response.
5987             IP address triggers are encoded in records that have owner names
5988             that are subdomains of <strong class="userinput"><code>rpz-ip</code></strong> relativized
5989             to the RPZ origin name and encode an IP address or address block.
5990             IPv4 trigger addresses are represented as
5991             <strong class="userinput"><code>prefixlength.B4.B3.B2.B1.rpz-ip</code></strong>.
5992             The prefix length must be between 1 and 32.
5993             All four bytes, B4, B3, B2, and B1, must be present.
5994             B4 is the decimal value of the least significant byte of the
5995             IPv4 address as in IN-ADDR.ARPA.
5996             IPv6 addresses are encoded in a format similar to the standard
5997             IPv6 text representation,
5998             <strong class="userinput"><code>prefixlength.W8.W7.W6.W5.W4.W3.W2.W1.rpz-ip</code></strong>.
5999             Each of W8,...,W1 is a one to four digit hexadecimal number
6000             representing 16 bits of the IPv6 address as in the standard text
6001             representation of IPv6 addresses, but reversed as in IN-ADDR.ARPA.
6002             All 8 words must be present except when consecutive
6003             zero words are replaced with <strong class="userinput"><code>.zz.</code></strong>
6004             analogous to double colons (::) in standard IPv6 text encodings.
6005             The prefix length must be between 1 and 128.
6006           </p>
6007 <p>
6008             NSDNAME triggers match names of authoritative servers
6009             for the query name, a parent of the query name, a CNAME for
6010             query name, or a parent of a CNAME.
6011             They are encoded as subdomains of
6012             <strong class="userinput"><code>rpz-nsdomain</code></strong> relativized
6013             to the RPZ origin name.
6014             NSIP triggers match IP addresses in A and
6015             AAAA RRsets for domains that can be checked against NSDNAME
6016             policy records.
6017             NSIP triggers are encoded like IP triggers except as subdomains of
6018             <strong class="userinput"><code>rpz-nsip</code></strong>.
6019             NSDNAME and NSIP triggers are checked only for names with at
6020             least <span><strong class="command">min-ns-dots</strong></span> dots.
6021             The default value of <span><strong class="command">min-ns-dots</strong></span> is 1 to
6022             exclude top level domains.
6023           </p>
6024 <p>
6025             The query response is checked against all RPZs, so
6026             two or more policy records can be triggered by a response.
6027             Because DNS responses can be rewritten according to at most one
6028             policy record, a single record encoding an action (other than
6029             <span><strong class="command">DISABLED</strong></span> actions) must be chosen.
6030             Triggers or the records that encode them are chosen in
6031             the following order:
6032             </p>
6033 <div class="itemizedlist"><ul type="disc">
6034 <li>Choose the triggered record in the zone that appears
6035                 first in the response-policy option.
6036               </li>
6037 <li>Prefer QNAME to IP to NSDNAME to NSIP triggers
6038                 in a single zone.
6039               </li>
6040 <li>Among NSDNAME triggers, prefer the
6041                 trigger that matches the smallest name under the DNSSEC ordering.
6042               </li>
6043 <li>Among IP or NSIP triggers, prefer the trigger
6044                 with the longest prefix.
6045               </li>
6046 <li>Among triggers with the same prefix length,
6047                 prefer the IP or NSIP trigger that matches
6048                 the smallest IP address.
6049               </li>
6050 </ul></div>
6051 <p>
6052           </p>
6053 <p>
6054             When the processing of a response is restarted to resolve
6055             DNAME or CNAME records and a policy record set has
6056             not been triggered,
6057             all RPZs are again consulted for the DNAME or CNAME names
6058             and addresses.
6059           </p>
6060 <p>
6061             RPZ record sets are sets of any types of DNS record except
6062             DNAME or DNSSEC that encode actions or responses to queries.
6063             </p>
6064 <div class="itemizedlist"><ul type="disc">
6065 <li>The <span><strong class="command">NXDOMAIN</strong></span> response is encoded
6066                 by a CNAME whose target is the root domain (.)
6067               </li>
6068 <li>A CNAME whose target is the wildcard top-level
6069                 domain (*.) specifies the <span><strong class="command">NODATA</strong></span> action,
6070                 which rewrites the response to NODATA or ANCOUNT=1.
6071               </li>
6072 <li>The <span><strong class="command">Local Data</strong></span> action is
6073                 represented by a set ordinary DNS records that are used
6074                 to answer queries.  Queries for record types not the
6075                 set are answered with NODATA.
6076
6077                 A special form of local data is a CNAME whose target is a
6078                 wildcard such as *.example.com.
6079                 It is used as if were an ordinary CNAME after the astrisk (*)
6080                 has been replaced with the query name.
6081                 The purpose for this special form is query logging in the
6082                 walled garden's authority DNS server.
6083               </li>
6084 <li>The <span><strong class="command">PASSTHRU</strong></span> policy is specified
6085                 by a CNAME whose target is <span><strong class="command">rpz-passthru.</strong></span>
6086                 It causes the response to not be rewritten
6087                 and is most often used to "poke holes" in policies for
6088                 CIDR blocks.
6089                 (A CNAME whose target is the variable part of its owner name
6090                 is an obsolete specification of the PASSTHRU policy.)
6091               </li>
6092 </ul></div>
6093 <p>
6094           </p>
6095 <p>
6096             The actions specified in an RPZ can be overridden with a
6097             <span><strong class="command">policy</strong></span> clause in the
6098             <span><strong class="command">response-policy</strong></span> option.
6099             An organization using an RPZ provided by another organization might
6100             use this mechanism to redirect domains to its own walled garden.
6101             </p>
6102 <div class="itemizedlist"><ul type="disc">
6103 <li>
6104 <span><strong class="command">GIVEN</strong></span> says "do not override but
6105                 perform the action specified in the zone."
6106               </li>
6107 <li>
6108 <span><strong class="command">DISABLED</strong></span> causes policy records to do
6109                 nothing but log what they might have done.
6110                 The response to the DNS query will be written according to
6111                 any triggered policy records that are not disabled.
6112                 Disabled policy zones should appear first,
6113                 because they will often not be logged
6114                 if a higher precedence trigger is found first.
6115               </li>
6116 <li>
6117 <span><strong class="command">PASSTHRU</strong></span> causes all policy records
6118                 to act as if they were CNAME records with targets the variable
6119                 part of their owner name.  They protect the response from
6120                 being changed.
6121               </li>
6122 <li>
6123 <span><strong class="command">NXDOMAIN</strong></span> causes all RPZ records
6124                 to specify NXDOMAIN policies.
6125               </li>
6126 <li>
6127 <span><strong class="command">NODATA</strong></span> overrides with the
6128                 NODATA policy
6129               </li>
6130 <li>
6131 <span><strong class="command">CNAME domain</strong></span> causes all RPZ
6132                 policy records to act as if they were "cname domain" records.
6133               </li>
6134 </ul></div>
6135 <p>
6136           </p>
6137 <p>
6138             By default, the actions encoded in an RPZ are applied
6139             only to queries that ask for recursion (RD=1).
6140             That default can be changed for a single RPZ or all RPZs in a view
6141             with a <span><strong class="command">recursive-only no</strong></span> clause.
6142             This feature is useful for serving the same zone files
6143             both inside and outside an RFC 1918 cloud and using RPZ to
6144             delete answers that would otherwise contain RFC 1918 values
6145             on the externally visible name server or view.
6146           </p>
6147 <p>
6148             Also by default, RPZ actions are applied only to DNS requests that
6149             either do not request DNSSEC metadata (DO=0) or when no DNSSEC
6150             records are available for request name in the original zone (not
6151             the response policy zone).
6152             This default can be changed for all RPZs in a view with a
6153             <span><strong class="command">break-dnssec yes</strong></span> clause.
6154             In that case, RPZ actions are applied regardless of DNSSEC.
6155             The name of the clause option reflects the fact that results
6156             rewritten by RPZ actions cannot verify.
6157           </p>
6158 <p>
6159             The TTL of a record modified by RPZ policies is set from the
6160             TTL of the relevant record in policy zone.  It is then limited
6161             to a maximum value.
6162             The <span><strong class="command">max-policy-ttl</strong></span> clause changes that
6163             maximum from its default of 5.
6164           </p>
6165 <p>
6166             For example, you might use this option statement
6167           </p>
6168 <pre class="programlisting">    response-policy { zone "badlist"; };</pre>
6169 <p>
6170             and this zone statement
6171           </p>
6172 <pre class="programlisting">    zone "badlist" {type master; file "master/badlist"; allow-query {none;}; };</pre>
6173 <p>
6174             with this zone file
6175           </p>
6176 <pre class="programlisting">$TTL 1H
6177 @                       SOA LOCALHOST. named-mgr.example.com (1 1h 15m 30d 2h)
6178                         NS  LOCALHOST.
6179
6180 ; QNAME policy records.  There are no periods (.) after the owner names.
6181 nxdomain.domain.com     CNAME   .               ; NXDOMAIN policy
6182 nodata.domain.com       CNAME   *.              ; NODATA policy
6183 bad.domain.com          A       10.0.0.1        ; redirect to a walled garden
6184                         AAAA    2001:2::1
6185
6186 ; do not rewrite (PASSTHRU) OK.DOMAIN.COM
6187 ok.domain.com           CNAME   rpz-passthru.
6188
6189 bzone.domain.com        CNAME   garden.example.com.
6190
6191 ; redirect x.bzone.domain.com to x.bzone.domain.com.garden.example.com
6192 *.bzone.domain.com      CNAME   *.garden.example.com.
6193
6194
6195 ; IP policy records that rewrite all answers for 127/8 except 127.0.0.1
6196 8.0.0.0.127.rpz-ip      CNAME   .
6197 32.1.0.0.127.rpz-ip     CNAME   rpz-passthru.
6198
6199 ; NSDNAME and NSIP policy records
6200 ns.domain.com.rpz-nsdname   CNAME   .
6201 48.zz.2.2001.rpz-nsip       CNAME   .
6202 </pre>
6203 <p>
6204             RPZ can affect server performance.
6205             Each configured response policy zone requires the server to
6206             perform one to four additional database lookups before a
6207             query can be answered.
6208             For example, a DNS server with four policy zones, each with all
6209             four kinds of response triggers, QNAME, IP, NSIP, and
6210             NSDNAME, requires a total of 17 times as many database
6211             lookups as a similar DNS server with no response policy zones.
6212             A <acronym class="acronym">BIND9</acronym> server with adequate memory and one
6213             response policy zone with QNAME and IP triggers might achieve a
6214             maximum queries-per-second rate about 20% lower.
6215             A server with four response policy zones with QNAME and IP
6216             triggers might have a maximum QPS rate about 50% lower.
6217           </p>
6218 <p>
6219             Responses rewritten by RPZ are counted in the
6220             <span><strong class="command">RPZRewrites</strong></span> statistics.
6221           </p>
6222 </div>
6223 <div class="sect3" lang="en">
6224 <div class="titlepage"><div><div><h4 class="title">
6225 <a name="id2589264"></a>Response Rate Limiting</h4></div></div></div>
6226 <p>
6227             This feature is only available when <acronym class="acronym">BIND</acronym> 9
6228             is compiled with the <strong class="userinput"><code>--enable-rrl</code></strong>
6229             option on the "configure" command line.
6230           </p>
6231 <p>
6232             Excessive almost identical UDP <span class="emphasis"><em>responses</em></span>
6233             can be controlled by configuring a
6234             <span><strong class="command">rate-limit</strong></span> clause in an
6235             <span><strong class="command">options</strong></span> or <span><strong class="command">view</strong></span> statement.
6236             This mechanism keeps authoritative BIND 9 from being used
6237             in amplifying reflection denial of service (DoS) attacks.
6238             Short truncated (TC=1) responses can be sent to provide
6239             rate-limited responses to legitimate clients within
6240             a range of forged, attacked IP addresses.
6241             Legitimate clients react to dropped or truncated response
6242             by retrying with UDP or with TCP respectively.
6243           </p>
6244 <p>
6245             This mechanism is intended for authoritative DNS servers.
6246             It can be used on recursive servers but can slow
6247             applications such as SMTP servers (mail receivers) and
6248             HTTP clients (web browsers) that repeatedly request the
6249             same domains.
6250             When possible, closing "open" recursive servers is better.
6251           </p>
6252 <p>
6253             Response rate limiting uses a "credit" or "token bucket" scheme.
6254             Each combination of identical response and client
6255             has a conceptual account that earns a specified number
6256             of credits every second.
6257             A prospective response debits its account by one.
6258             Responses are dropped or truncated
6259             while the account is negative.
6260             Responses are tracked within a rolling window of time
6261             which defaults to 15 seconds, but can be configured with
6262             the <span><strong class="command">window</strong></span> option to any value from
6263             1 to 3600 seconds (1 hour).
6264             The account cannot become more positive than
6265             the per-second limit
6266             or more negative than <span><strong class="command">window</strong></span>
6267             times the per-second limit.
6268             When the specified number of credits for a class of
6269             responses is set to 0, those responses are not rate limited.
6270           </p>
6271 <p>
6272             The notions of "identical response" and "DNS client"
6273             for rate limiting are not simplistic.
6274             All responses to an address block are counted as if to a
6275             single client.
6276             The prefix lengths of addresses blocks are
6277             specified with <span><strong class="command">ipv4-prefix-length</strong></span> (default 24)
6278             and <span><strong class="command">ipv6-prefix-length</strong></span> (default 56).
6279           </p>
6280 <p>
6281             All non-empty responses for a valid domain name (qname)
6282             and record type (qtype) are identical and have a limit specified
6283             with <span><strong class="command">responses-per-second</strong></span>
6284             (default 0 or no limit).
6285             All empty (NODATA) responses for a valid domain,
6286             regardless of query type, are identical.
6287             Responses in the NODATA class are limited by
6288             <span><strong class="command">nodata-per-second</strong></span>
6289             (default <span><strong class="command">responses-per-second</strong></span>).
6290             Requests for any and all undefined subdomains of a given
6291             valid domain result in NXDOMAIN errors, and are identical
6292             regardless of query type.
6293             They are limited by <span><strong class="command">nxdomain-per-second</strong></span>
6294             (default <span><strong class="command">responses-per-second</strong></span>).
6295             This controls some attacks using random names, but
6296             can be relaxed or turned off (set to 0)
6297             on servers that expect many legitimate
6298             NXDOMAIN responses, such as from anti-spam blacklists.
6299             Referrals or delegations to the server of a given
6300             domain are identical and are limited by
6301             <span><strong class="command">referrals-per-second</strong></span>
6302             (default <span><strong class="command">responses-per-second</strong></span>).
6303           </p>
6304 <p>
6305             Responses generated from local wildcards are counted and limited
6306             as if they were for the parent domain name.
6307             This controls flooding using random.wild.example.com.
6308           </p>
6309 <p>
6310             All requests that result in DNS errors other
6311             than NXDOMAIN, such as SERVFAIL and FORMERR, are identical
6312             regardless of requested name (qname) or record type (qtype).
6313             This controls attacks using invalid requests or distant,
6314             broken authoritative servers.
6315             By default the limit on errors is the same as the
6316             <span><strong class="command">responses-per-second</strong></span> value,
6317             but it can be set separately with
6318             <span><strong class="command">errors-per-second</strong></span>.
6319           </p>
6320 <p>
6321             Many attacks using DNS involve UDP requests with forged source
6322             addresses.
6323             Rate limiting prevents the use of BIND 9 to flood a network
6324             with responses to requests with forged source addresses,
6325             but could let a third party block responses to legitimate requests.
6326             There is a mechanism that can answer some legitimate
6327             requests from a client whose address is being forged in a flood.
6328             Setting <span><strong class="command">slip</strong></span> to 2 (its default) causes every
6329             other UDP request to be answered with a small truncated (TC=1)
6330             response.
6331             The small size and reduced frequency, and so lack of
6332             amplification, of "slipped" responses make them unattractive
6333             for reflection DoS attacks.
6334             <span><strong class="command">slip</strong></span> must be between 0 and 10.
6335             A value of 0 does not "slip":
6336             no truncated responses are sent due to rate limiting,
6337             all responses are dropped.
6338             A value of 1 causes every response to slip;
6339             values between 2 and 10 cause every n'th response to slip.
6340             Some error responses including REFUSED and SERVFAIL
6341             cannot be replaced with truncated responses and are instead
6342             leaked at the <span><strong class="command">slip</strong></span> rate.
6343           </p>
6344 <p>
6345             (NOTE: Dropped responses from an authoritative server may
6346             reduce the difficulty of a third party successfully forging
6347             a response to a recursive resolver. The best security
6348             against forged responses is for authoritative operators
6349             to sign their zones using DNSSEC and for resolver operators
6350             to validate the responses. When this is not an option,
6351             operators who are more concerned with response integrity
6352             than with flood mitigation may consider setting
6353             <span><strong class="command">slip</strong></span> to 1, causing all rate-limited
6354             responses to be truncated rather than dropped.  This reduces
6355             the effectiveness of rate-limiting against reflection attacks.)
6356           </p>
6357 <p>
6358             When the approximate query per second rate exceeds
6359             the <span><strong class="command">qps-scale</strong></span> value,
6360             then the <span><strong class="command">responses-per-second</strong></span>,
6361             <span><strong class="command">errors-per-second</strong></span>,
6362             <span><strong class="command">nxdomains-per-second</strong></span> and
6363             <span><strong class="command">all-per-second</strong></span> values are reduced by the
6364             ratio of the current rate to the <span><strong class="command">qps-scale</strong></span> value.
6365             This feature can tighten defenses during attacks.
6366             For example, with
6367             <span><strong class="command">qps-scale 250; responses-per-second 20;</strong></span> and
6368             a total query rate of 1000 queries/second for all queries from
6369             all DNS clients including via TCP,
6370             then the effective responses/second limit changes to
6371             (250/1000)*20 or 5.
6372             Responses sent via TCP are not limited
6373             but are counted to compute the query per second rate.
6374           </p>
6375 <p>
6376             Communities of DNS clients can be given their own parameters or no
6377             rate limiting by putting
6378             <span><strong class="command">rate-limit</strong></span> statements in <span><strong class="command">view</strong></span>
6379             statements instead of the global <span><strong class="command">option</strong></span>
6380             statement.
6381             A <span><strong class="command">rate-limit</strong></span> statement in a view replaces,
6382             rather than supplementing, a <span><strong class="command">rate-limit</strong></span>
6383             statement among the main options.
6384             DNS clients within a view can be exempted from rate limits
6385             with the <span><strong class="command">exempt-clients</strong></span> clause.
6386           </p>
6387 <p>
6388             UDP responses of all kinds can be limited with the
6389             <span><strong class="command">all-per-second</strong></span> phrase.
6390             This rate limiting is unlike the rate limiting provided by
6391             <span><strong class="command">responses-per-second</strong></span>,
6392             <span><strong class="command">errors-per-second</strong></span>, and
6393             <span><strong class="command">nxdomains-per-second</strong></span> on a DNS server
6394             which are often invisible to the victim of a DNS reflection attack.
6395             Unless the forged requests of the attack are the same as the
6396             legitimate requests of the victim, the victim's requests are
6397             not affected.
6398             Responses affected by an <span><strong class="command">all-per-second</strong></span> limit
6399             are always dropped; the <span><strong class="command">slip</strong></span> value has no
6400             effect.
6401             An <span><strong class="command">all-per-second</strong></span> limit should be
6402             at least 4 times as large as the other limits,
6403             because single DNS clients often send bursts of legitimate
6404             requests.
6405             For example, the receipt of a single mail message can prompt
6406             requests from an SMTP server for NS, PTR, A, and AAAA records
6407             as the incoming SMTP/TCP/IP connection is considered.
6408             The SMTP server can need additional NS, A, AAAA, MX, TXT, and SPF
6409             records as it considers the STMP <span><strong class="command">Mail From</strong></span>
6410             command.
6411             Web browsers often repeatedly resolve the same names that
6412             are repeated in HTML &lt;IMG&gt; tags in a page.
6413             <span><strong class="command">All-per-second</strong></span> is similar to the
6414             rate limiting offered by firewalls but often inferior.
6415             Attacks that justify ignoring the
6416             contents of DNS responses are likely to be attacks on the
6417             DNS server itself.
6418             They usually should be discarded before the DNS server
6419             spends resources making TCP connections or parsing DNS requests,
6420             but that rate limiting must be done before the
6421             DNS server sees the requests.
6422           </p>
6423 <p>
6424             The maximum size of the table used to track requests and
6425             rate limit responses is set with <span><strong class="command">max-table-size</strong></span>.
6426             Each entry in the table is between 40 and 80 bytes.
6427             The table needs approximately as many entries as the number
6428             of requests received per second.
6429             The default is 20,000.
6430             To reduce the cold start of growing the table,
6431             <span><strong class="command">min-table-size</strong></span> (default 500)
6432             can set the minimum table size.
6433             Enable <span><strong class="command">rate-limit</strong></span> category logging to monitor
6434             expansions of the table and inform
6435             choices for the initial and maximum table size.
6436           </p>
6437 <p>
6438             Use <span><strong class="command">log-only yes</strong></span> to test rate limiting parameters
6439             without actually dropping any requests.
6440           </p>
6441 <p>
6442             Responses dropped by rate limits are included in the
6443             <span><strong class="command">RateDropped</strong></span> and <span><strong class="command">QryDropped</strong></span>
6444             statistics.
6445             Responses that truncated by rate limits are included in
6446             <span><strong class="command">RateSlipped</strong></span> and <span><strong class="command">RespTruncated</strong></span>.
6447           </p>
6448 </div>
6449 </div>
6450 <div class="sect2" lang="en">
6451 <div class="titlepage"><div><div><h3 class="title">
6452 <a name="server_statement_grammar"></a><span><strong class="command">server</strong></span> Statement Grammar</h3></div></div></div>
6453 <pre class="programlisting"><span><strong class="command">server</strong></span> <em class="replaceable"><code>ip_addr[/prefixlen]</code></em> {
6454     [<span class="optional"> bogus <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
6455     [<span class="optional"> provide-ixfr <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
6456     [<span class="optional"> request-ixfr <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
6457     [<span class="optional"> request-nsid <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
6458     [<span class="optional"> edns <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
6459     [<span class="optional"> edns-udp-size <em class="replaceable"><code>number</code></em> ; </span>]
6460     [<span class="optional"> max-udp-size <em class="replaceable"><code>number</code></em> ; </span>]
6461     [<span class="optional"> transfers <em class="replaceable"><code>number</code></em> ; </span>]
6462     [<span class="optional"> transfer-format <em class="replaceable"><code>( one-answer | many-answers )</code></em> ; ]</span>]
6463     [<span class="optional"> keys <em class="replaceable"><code>{ string ; [<span class="optional"> string ; [<span class="optional">...</span>]</span>] }</code></em> ; </span>]
6464     [<span class="optional"> transfer-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
6465     [<span class="optional"> transfer-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
6466     [<span class="optional"> notify-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
6467     [<span class="optional"> notify-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
6468     [<span class="optional"> query-source [<span class="optional"> address ( <em class="replaceable"><code>ip_addr</code></em> | <em class="replaceable"><code>*</code></em> ) </span>]
6469                   [<span class="optional"> port ( <em class="replaceable"><code>ip_port</code></em> | <em class="replaceable"><code>*</code></em> ) </span>]; </span>]
6470     [<span class="optional"> query-source-v6 [<span class="optional"> address ( <em class="replaceable"><code>ip_addr</code></em> | <em class="replaceable"><code>*</code></em> ) </span>]
6471                      [<span class="optional"> port ( <em class="replaceable"><code>ip_port</code></em> | <em class="replaceable"><code>*</code></em> ) </span>]; </span>]
6472     [<span class="optional"> use-queryport-pool <em class="replaceable"><code>yes_or_no</code></em>; </span>]
6473     [<span class="optional"> queryport-pool-ports <em class="replaceable"><code>number</code></em>; </span>]
6474     [<span class="optional"> queryport-pool-updateinterval <em class="replaceable"><code>number</code></em>; </span>]
6475 };
6476 </pre>
6477 </div>
6478 <div class="sect2" lang="en">
6479 <div class="titlepage"><div><div><h3 class="title">
6480 <a name="server_statement_definition_and_usage"></a><span><strong class="command">server</strong></span> Statement Definition and
6481             Usage</h3></div></div></div>
6482 <p>
6483             The <span><strong class="command">server</strong></span> statement defines
6484             characteristics
6485             to be associated with a remote name server.  If a prefix length is
6486             specified, then a range of servers is covered.  Only the most
6487             specific
6488             server clause applies regardless of the order in
6489             <code class="filename">named.conf</code>.
6490           </p>
6491 <p>
6492             The <span><strong class="command">server</strong></span> statement can occur at
6493             the top level of the
6494             configuration file or inside a <span><strong class="command">view</strong></span>
6495             statement.
6496             If a <span><strong class="command">view</strong></span> statement contains
6497             one or more <span><strong class="command">server</strong></span> statements, only
6498             those
6499             apply to the view and any top-level ones are ignored.
6500             If a view contains no <span><strong class="command">server</strong></span>
6501             statements,
6502             any top-level <span><strong class="command">server</strong></span> statements are
6503             used as
6504             defaults.
6505           </p>
6506 <p>
6507             If you discover that a remote server is giving out bad data,
6508             marking it as bogus will prevent further queries to it. The
6509             default
6510             value of <span><strong class="command">bogus</strong></span> is <span><strong class="command">no</strong></span>.
6511           </p>
6512 <p>
6513             The <span><strong class="command">provide-ixfr</strong></span> clause determines
6514             whether
6515             the local server, acting as master, will respond with an
6516             incremental
6517             zone transfer when the given remote server, a slave, requests it.
6518             If set to <span><strong class="command">yes</strong></span>, incremental transfer
6519             will be provided
6520             whenever possible. If set to <span><strong class="command">no</strong></span>,
6521             all transfers
6522             to the remote server will be non-incremental. If not set, the
6523             value
6524             of the <span><strong class="command">provide-ixfr</strong></span> option in the
6525             view or
6526             global options block is used as a default.
6527           </p>
6528 <p>
6529             The <span><strong class="command">request-ixfr</strong></span> clause determines
6530             whether
6531             the local server, acting as a slave, will request incremental zone
6532             transfers from the given remote server, a master. If not set, the
6533             value of the <span><strong class="command">request-ixfr</strong></span> option in
6534             the view or global options block is used as a default. It may
6535             also be set in the zone block and, if set there, it will
6536             override the global or view setting for that zone.
6537           </p>
6538 <p>
6539             IXFR requests to servers that do not support IXFR will
6540             automatically
6541             fall back to AXFR.  Therefore, there is no need to manually list
6542             which servers support IXFR and which ones do not; the global
6543             default
6544             of <span><strong class="command">yes</strong></span> should always work.
6545             The purpose of the <span><strong class="command">provide-ixfr</strong></span> and
6546             <span><strong class="command">request-ixfr</strong></span> clauses is
6547             to make it possible to disable the use of IXFR even when both
6548             master
6549             and slave claim to support it, for example if one of the servers
6550             is buggy and crashes or corrupts data when IXFR is used.
6551           </p>
6552 <p>
6553             The <span><strong class="command">edns</strong></span> clause determines whether
6554             the local server will attempt to use EDNS when communicating
6555             with the remote server.  The default is <span><strong class="command">yes</strong></span>.
6556           </p>
6557 <p>
6558             The <span><strong class="command">edns-udp-size</strong></span> option sets the EDNS UDP size
6559             that is advertised by <span><strong class="command">named</strong></span> when querying the remote server.
6560             Valid values are 512 to 4096 bytes (values outside this range will be
6561             silently adjusted).  This option is useful when you wish to
6562             advertises a different value to this server than the value you
6563             advertise globally, for example, when there is a firewall at the
6564             remote site that is blocking large replies.
6565           </p>
6566 <p>
6567             The <span><strong class="command">max-udp-size</strong></span> option sets the
6568             maximum EDNS UDP message size <span><strong class="command">named</strong></span> will send.  Valid
6569             values are 512 to 4096 bytes (values outside this range will
6570             be silently adjusted).  This option is useful when you
6571             know that there is a firewall that is blocking large
6572             replies from <span><strong class="command">named</strong></span>.
6573           </p>
6574 <p>
6575             The server supports two zone transfer methods. The first, <span><strong class="command">one-answer</strong></span>,
6576             uses one DNS message per resource record transferred. <span><strong class="command">many-answers</strong></span> packs
6577             as many resource records as possible into a message. <span><strong class="command">many-answers</strong></span> is
6578             more efficient, but is only known to be understood by <acronym class="acronym">BIND</acronym> 9, <acronym class="acronym">BIND</acronym>
6579             8.x, and patched versions of <acronym class="acronym">BIND</acronym>
6580             4.9.5. You can specify which method
6581             to use for a server with the <span><strong class="command">transfer-format</strong></span> option.
6582             If <span><strong class="command">transfer-format</strong></span> is not
6583             specified, the <span><strong class="command">transfer-format</strong></span>
6584             specified
6585             by the <span><strong class="command">options</strong></span> statement will be
6586             used.
6587           </p>
6588 <p><span><strong class="command">transfers</strong></span>
6589             is used to limit the number of concurrent inbound zone
6590             transfers from the specified server. If no
6591             <span><strong class="command">transfers</strong></span> clause is specified, the
6592             limit is set according to the
6593             <span><strong class="command">transfers-per-ns</strong></span> option.
6594           </p>
6595 <p>
6596             The <span><strong class="command">keys</strong></span> clause identifies a
6597             <span><strong class="command">key_id</strong></span> defined by the <span><strong class="command">key</strong></span> statement,
6598             to be used for transaction security (TSIG, <a href="Bv9ARM.ch04.html#tsig" title="TSIG">the section called &#8220;TSIG&#8221;</a>)
6599             when talking to the remote server.
6600             When a request is sent to the remote server, a request signature
6601             will be generated using the key specified here and appended to the
6602             message. A request originating from the remote server is not
6603             required
6604             to be signed by this key.
6605           </p>
6606 <p>
6607             Although the grammar of the <span><strong class="command">keys</strong></span>
6608             clause
6609             allows for multiple keys, only a single key per server is
6610             currently
6611             supported.
6612           </p>
6613 <p>
6614             The <span><strong class="command">transfer-source</strong></span> and
6615             <span><strong class="command">transfer-source-v6</strong></span> clauses specify
6616             the IPv4 and IPv6 source
6617             address to be used for zone transfer with the remote server,
6618             respectively.
6619             For an IPv4 remote server, only <span><strong class="command">transfer-source</strong></span> can
6620             be specified.
6621             Similarly, for an IPv6 remote server, only
6622             <span><strong class="command">transfer-source-v6</strong></span> can be
6623             specified.
6624             For more details, see the description of
6625             <span><strong class="command">transfer-source</strong></span> and
6626             <span><strong class="command">transfer-source-v6</strong></span> in
6627             <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
6628           </p>
6629 <p>
6630             The <span><strong class="command">notify-source</strong></span> and
6631             <span><strong class="command">notify-source-v6</strong></span> clauses specify the
6632             IPv4 and IPv6 source address to be used for notify
6633             messages sent to remote servers, respectively.  For an
6634             IPv4 remote server, only <span><strong class="command">notify-source</strong></span>
6635             can be specified.  Similarly, for an IPv6 remote server,
6636             only <span><strong class="command">notify-source-v6</strong></span> can be specified.
6637           </p>
6638 <p>
6639             The <span><strong class="command">query-source</strong></span> and
6640             <span><strong class="command">query-source-v6</strong></span> clauses specify the
6641             IPv4 and IPv6 source address to be used for queries
6642             sent to remote servers, respectively.  For an IPv4
6643             remote server, only <span><strong class="command">query-source</strong></span> can
6644             be specified.  Similarly, for an IPv6 remote server,
6645             only <span><strong class="command">query-source-v6</strong></span> can be specified.
6646           </p>
6647 <p>
6648             The <span><strong class="command">request-nsid</strong></span> clause determines
6649             whether the local server will add a NSID EDNS option
6650             to requests sent to the server.  This overrides
6651             <span><strong class="command">request-nsid</strong></span> set at the view or
6652             option level. 
6653           </p>
6654 </div>
6655 <div class="sect2" lang="en">
6656 <div class="titlepage"><div><div><h3 class="title">
6657 <a name="statschannels"></a><span><strong class="command">statistics-channels</strong></span> Statement Grammar</h3></div></div></div>
6658 <pre class="programlisting"><span><strong class="command">statistics-channels</strong></span> {
6659    [ inet ( ip_addr | * ) [ port ip_port ]
6660    [ allow { <em class="replaceable"><code> address_match_list </code></em> } ]; ]
6661    [ inet ...; ]
6662 };
6663 </pre>
6664 </div>
6665 <div class="sect2" lang="en">
6666 <div class="titlepage"><div><div><h3 class="title">
6667 <a name="id2590489"></a><span><strong class="command">statistics-channels</strong></span> Statement Definition and
6668             Usage</h3></div></div></div>
6669 <p>
6670           The <span><strong class="command">statistics-channels</strong></span> statement
6671           declares communication channels to be used by system
6672           administrators to get access to statistics information of
6673           the name server.
6674         </p>
6675 <p>
6676           This statement intends to be flexible to support multiple
6677           communication protocols in the future, but currently only
6678           HTTP access is supported.
6679           It requires that BIND 9 be compiled with libxml2;
6680           the <span><strong class="command">statistics-channels</strong></span> statement is
6681           still accepted even if it is built without the library,
6682           but any HTTP access will fail with an error.
6683         </p>
6684 <p>
6685           An <span><strong class="command">inet</strong></span> control channel is a TCP socket
6686           listening at the specified <span><strong class="command">ip_port</strong></span> on the
6687           specified <span><strong class="command">ip_addr</strong></span>, which can be an IPv4 or IPv6
6688           address.  An <span><strong class="command">ip_addr</strong></span> of <code class="literal">*</code> (asterisk) is
6689           interpreted as the IPv4 wildcard address; connections will be
6690           accepted on any of the system's IPv4 addresses.
6691           To listen on the IPv6 wildcard address,
6692           use an <span><strong class="command">ip_addr</strong></span> of <code class="literal">::</code>.
6693         </p>
6694 <p>
6695           If no port is specified, port 80 is used for HTTP channels.
6696           The asterisk "<code class="literal">*</code>" cannot be used for
6697           <span><strong class="command">ip_port</strong></span>.
6698         </p>
6699 <p>
6700           The attempt of opening a statistics channel is
6701           restricted by the optional <span><strong class="command">allow</strong></span> clause.
6702           Connections to the statistics channel are permitted based on the
6703           <span><strong class="command">address_match_list</strong></span>.
6704           If no <span><strong class="command">allow</strong></span> clause is present,
6705           <span><strong class="command">named</strong></span> accepts connection
6706           attempts from any address; since the statistics may
6707           contain sensitive internal information, it is highly
6708           recommended to restrict the source of connection requests
6709           appropriately.
6710         </p>
6711 <p>
6712           If no <span><strong class="command">statistics-channels</strong></span> statement is present,
6713           <span><strong class="command">named</strong></span> will not open any communication channels.
6714         </p>
6715 <p>
6716           If the statistics channel is configured to listen on 127.0.0.1
6717           port 8888, then the statistics are accessible in XML format at
6718           <a href="http://127.0.0.1:8888/" target="_top">http://127.0.0.1:8888/</a> or
6719           <a href="http://127.0.0.1:8888/xml" target="_top">http://127.0.0.1:8888/xml</a>. A CSS file is
6720           included which can format the XML statistics into tables 
6721           when viewed with a stylesheet-capable browser.  When
6722           <acronym class="acronym">BIND</acronym> 9 is configured with --enable-newstats, 
6723           a new XML schema is used (version 3) which adds additional
6724           zone statistics and uses a flatter tree for more efficient
6725           parsing.  The stylesheet included uses the Google Charts API
6726           to render data into into charts and graphs when using a
6727           javascript-capable browser.
6728         </p>
6729 <p>
6730           Applications that depend on a particular XML schema
6731           can request 
6732           <a href="http://127.0.0.1:8888/xml/v2" target="_top">http://127.0.0.1:8888/xml/v2</a> for version 2
6733           of the statistics XML schema or 
6734           <a href="http://127.0.0.1:8888/xml/v3" target="_top">http://127.0.0.1:8888/xml/v3</a> for version 3.
6735           If the requested schema is supported by the server, then
6736           it will respond; if not, it will return a "page not found"
6737           error.
6738         </p>
6739 </div>
6740 <div class="sect2" lang="en">
6741 <div class="titlepage"><div><div><h3 class="title">
6742 <a name="trusted-keys"></a><span><strong class="command">trusted-keys</strong></span> Statement Grammar</h3></div></div></div>
6743 <pre class="programlisting"><span><strong class="command">trusted-keys</strong></span> {
6744     <em class="replaceable"><code>string</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>string</code></em> ;
6745     [<span class="optional"> <em class="replaceable"><code>string</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>string</code></em> ; [<span class="optional">...</span>]</span>]
6746 };
6747 </pre>
6748 </div>
6749 <div class="sect2" lang="en">
6750 <div class="titlepage"><div><div><h3 class="title">
6751 <a name="id2590796"></a><span><strong class="command">trusted-keys</strong></span> Statement Definition
6752             and Usage</h3></div></div></div>
6753 <p>
6754             The <span><strong class="command">trusted-keys</strong></span> statement defines
6755             DNSSEC security roots. DNSSEC is described in <a href="Bv9ARM.ch04.html#DNSSEC" title="DNSSEC">the section called &#8220;DNSSEC&#8221;</a>. A security root is defined when the
6756             public key for a non-authoritative zone is known, but
6757             cannot be securely obtained through DNS, either because
6758             it is the DNS root zone or because its parent zone is
6759             unsigned.  Once a key has been configured as a trusted
6760             key, it is treated as if it had been validated and
6761             proven secure. The resolver attempts DNSSEC validation
6762             on all DNS data in subdomains of a security root.
6763           </p>
6764 <p>
6765             All keys (and corresponding zones) listed in
6766             <span><strong class="command">trusted-keys</strong></span> are deemed to exist regardless
6767             of what parent zones say.  Similarly for all keys listed in
6768             <span><strong class="command">trusted-keys</strong></span> only those keys are
6769             used to validate the DNSKEY RRset.  The parent's DS RRset
6770             will not be used.
6771           </p>
6772 <p>
6773             The <span><strong class="command">trusted-keys</strong></span> statement can contain
6774             multiple key entries, each consisting of the key's
6775             domain name, flags, protocol, algorithm, and the Base-64
6776             representation of the key data.
6777             Spaces, tabs, newlines and carriage returns are ignored
6778             in the key data, so the configuration may be split up into
6779             multiple lines.
6780           </p>
6781 <p>
6782             <span><strong class="command">trusted-keys</strong></span> may be set at the top level
6783             of <code class="filename">named.conf</code> or within a view.  If it is
6784             set in both places, they are additive: keys defined at the top
6785             level are inherited by all views, but keys defined in a view
6786             are only used within that view.
6787           </p>
6788 </div>
6789 <div class="sect2" lang="en">
6790 <div class="titlepage"><div><div><h3 class="title">
6791 <a name="id2590843"></a><span><strong class="command">managed-keys</strong></span> Statement Grammar</h3></div></div></div>
6792 <pre class="programlisting"><span><strong class="command">managed-keys</strong></span> {
6793     <em class="replaceable"><code>name</code></em> initial-key <em class="replaceable"><code>flags</code></em> <em class="replaceable"><code>protocol</code></em> <em class="replaceable"><code>algorithm</code></em> <em class="replaceable"><code>key-data</code></em> ;
6794     [<span class="optional"> <em class="replaceable"><code>name</code></em> initial-key <em class="replaceable"><code>flags</code></em> <em class="replaceable"><code>protocol</code></em> <em class="replaceable"><code>algorithm</code></em> <em class="replaceable"><code>key-data</code></em> ; [<span class="optional">...</span>]</span>]
6795 };
6796 </pre>
6797 </div>
6798 <div class="sect2" lang="en">
6799 <div class="titlepage"><div><div><h3 class="title">
6800 <a name="managed-keys"></a><span><strong class="command">managed-keys</strong></span> Statement Definition
6801             and Usage</h3></div></div></div>
6802 <p>
6803             The <span><strong class="command">managed-keys</strong></span> statement, like 
6804             <span><strong class="command">trusted-keys</strong></span>, defines DNSSEC
6805             security roots.  The difference is that
6806             <span><strong class="command">managed-keys</strong></span> can be kept up to date
6807             automatically, without intervention from the resolver
6808             operator.
6809           </p>
6810 <p>
6811             Suppose, for example, that a zone's key-signing
6812             key was compromised, and the zone owner had to revoke and
6813             replace the key.  A resolver which had the old key in a
6814             <span><strong class="command">trusted-keys</strong></span> statement would be
6815             unable to validate this zone any longer; it would
6816             reply with a SERVFAIL response code.  This would
6817             continue until the resolver operator had updated the
6818             <span><strong class="command">trusted-keys</strong></span> statement with the new key.
6819           </p>
6820 <p>
6821             If, however, the zone were listed in a
6822             <span><strong class="command">managed-keys</strong></span> statement instead, then the
6823             zone owner could add a "stand-by" key to the zone in advance.
6824             <span><strong class="command">named</strong></span> would store the stand-by key, and
6825             when the original key was revoked, <span><strong class="command">named</strong></span>
6826             would be able to transition smoothly to the new key.  It would
6827             also recognize that the old key had been revoked, and cease
6828             using that key to validate answers, minimizing the damage that
6829             the compromised key could do.
6830           </p>
6831 <p>
6832             A <span><strong class="command">managed-keys</strong></span> statement contains a list of
6833             the keys to be managed, along with information about how the
6834             keys are to be initialized for the first time.  The only
6835             initialization method currently supported (as of
6836             <acronym class="acronym">BIND</acronym> 9.7.0) is <code class="literal">initial-key</code>.
6837             This means the <span><strong class="command">managed-keys</strong></span> statement must
6838             contain a copy of the initializing key.  (Future releases may
6839             allow keys to be initialized by other methods, eliminating this
6840             requirement.)
6841           </p>
6842 <p>
6843             Consequently, a <span><strong class="command">managed-keys</strong></span> statement
6844             appears similar to a <span><strong class="command">trusted-keys</strong></span>, differing
6845             in the presence of the second field, containing the keyword
6846             <code class="literal">initial-key</code>.  The difference is, whereas the
6847             keys listed in a <span><strong class="command">trusted-keys</strong></span> continue to be
6848             trusted until they are removed from
6849             <code class="filename">named.conf</code>, an initializing key listed 
6850             in a <span><strong class="command">managed-keys</strong></span> statement is only trusted
6851             <span class="emphasis"><em>once</em></span>: for as long as it takes to load the
6852             managed key database and start the RFC 5011 key maintenance
6853             process.
6854           </p>
6855 <p>
6856             The first time <span><strong class="command">named</strong></span> runs with a managed key
6857             configured in <code class="filename">named.conf</code>, it fetches the
6858             DNSKEY RRset directly from the zone apex, and validates it
6859             using the key specified in the <span><strong class="command">managed-keys</strong></span>
6860             statement.  If the DNSKEY RRset is validly signed, then it is
6861             used as the basis for a new managed keys database.
6862           </p>
6863 <p>
6864             From that point on, whenever <span><strong class="command">named</strong></span> runs, it
6865             sees the <span><strong class="command">managed-keys</strong></span> statement, checks to
6866             make sure RFC 5011 key maintenance has already been initialized
6867             for the specified domain, and if so, it simply moves on.  The
6868             key specified in the <span><strong class="command">managed-keys</strong></span> is not
6869             used to validate answers; it has been superseded by the key or
6870             keys stored in the managed keys database.
6871           </p>
6872 <p>
6873             The next time <span><strong class="command">named</strong></span> runs after a name
6874             has been <span class="emphasis"><em>removed</em></span> from the
6875             <span><strong class="command">managed-keys</strong></span> statement, the corresponding
6876             zone will be removed from the managed keys database,
6877             and RFC 5011 key maintenance will no longer be used for that
6878             domain.
6879           </p>
6880 <p>
6881             <span><strong class="command">named</strong></span> only maintains a single managed keys
6882             database; consequently, unlike <span><strong class="command">trusted-keys</strong></span>,
6883             <span><strong class="command">managed-keys</strong></span> may only be set at the top
6884             level of <code class="filename">named.conf</code>, not within a view.
6885           </p>
6886 <p>
6887             In the current implementation, the managed keys database is
6888             stored as a master-format zone file called
6889             <code class="filename">managed-keys.bind</code>.  When the key database
6890             is changed, the zone is updated.  As with any other dynamic
6891             zone, changes will be written into a journal file,
6892             <code class="filename">managed-keys.bind.jnl</code>.  They are committed
6893             to the master file as soon as possible afterward; in the case
6894             of the managed key database, this will usually occur within 30
6895             seconds.  So, whenever <span><strong class="command">named</strong></span> is using
6896             automatic key maintenance, those two files can be expected to
6897             exist in the working directory.  (For this reason among others,
6898             the working directory should be always be writable by
6899             <span><strong class="command">named</strong></span>.)
6900           </p>
6901 <p>
6902             If the <span><strong class="command">dnssec-validation</strong></span> option is
6903             set to <strong class="userinput"><code>auto</code></strong>, <span><strong class="command">named</strong></span>
6904             will automatically initialize a managed key for the
6905             root zone.  Similarly, if the <span><strong class="command">dnssec-lookaside</strong></span>
6906             option is set to <strong class="userinput"><code>auto</code></strong>,
6907             <span><strong class="command">named</strong></span> will automatically initialize
6908             a managed key for the zone <code class="literal">dlv.isc.org</code>.
6909             In both cases, the key that is used to initialize the key
6910             maintenance process is built into <span><strong class="command">named</strong></span>,
6911             and can be overridden from <span><strong class="command">bindkeys-file</strong></span>.
6912           </p>
6913 </div>
6914 <div class="sect2" lang="en">
6915 <div class="titlepage"><div><div><h3 class="title">
6916 <a name="view_statement_grammar"></a><span><strong class="command">view</strong></span> Statement Grammar</h3></div></div></div>
6917 <pre class="programlisting"><span><strong class="command">view</strong></span> <em class="replaceable"><code>view_name</code></em>
6918       [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
6919       match-clients { <em class="replaceable"><code>address_match_list</code></em> };
6920       match-destinations { <em class="replaceable"><code>address_match_list</code></em> };
6921       match-recursive-only <em class="replaceable"><code>yes_or_no</code></em> ;
6922       [<span class="optional"> <em class="replaceable"><code>view_option</code></em>; ...</span>]
6923       [<span class="optional"> <em class="replaceable"><code>zone_statement</code></em>; ...</span>]
6924 };
6925 </pre>
6926 </div>
6927 <div class="sect2" lang="en">
6928 <div class="titlepage"><div><div><h3 class="title">
6929 <a name="id2591278"></a><span><strong class="command">view</strong></span> Statement Definition and Usage</h3></div></div></div>
6930 <p>
6931             The <span><strong class="command">view</strong></span> statement is a powerful
6932             feature
6933             of <acronym class="acronym">BIND</acronym> 9 that lets a name server
6934             answer a DNS query differently
6935             depending on who is asking. It is particularly useful for
6936             implementing
6937             split DNS setups without having to run multiple servers.
6938           </p>
6939 <p>
6940             Each <span><strong class="command">view</strong></span> statement defines a view
6941             of the
6942             DNS namespace that will be seen by a subset of clients.  A client
6943             matches
6944             a view if its source IP address matches the
6945             <code class="varname">address_match_list</code> of the view's
6946             <span><strong class="command">match-clients</strong></span> clause and its
6947             destination IP address matches
6948             the <code class="varname">address_match_list</code> of the
6949             view's
6950             <span><strong class="command">match-destinations</strong></span> clause.  If not
6951             specified, both
6952             <span><strong class="command">match-clients</strong></span> and <span><strong class="command">match-destinations</strong></span>
6953             default to matching all addresses.  In addition to checking IP
6954             addresses
6955             <span><strong class="command">match-clients</strong></span> and <span><strong class="command">match-destinations</strong></span>
6956             can also take <span><strong class="command">keys</strong></span> which provide an
6957             mechanism for the
6958             client to select the view.  A view can also be specified
6959             as <span><strong class="command">match-recursive-only</strong></span>, which
6960             means that only recursive
6961             requests from matching clients will match that view.
6962             The order of the <span><strong class="command">view</strong></span> statements is
6963             significant &#8212;
6964             a client request will be resolved in the context of the first
6965             <span><strong class="command">view</strong></span> that it matches.
6966           </p>
6967 <p>
6968             Zones defined within a <span><strong class="command">view</strong></span>
6969             statement will
6970             only be accessible to clients that match the <span><strong class="command">view</strong></span>.
6971             By defining a zone of the same name in multiple views, different
6972             zone data can be given to different clients, for example,
6973             "internal"
6974             and "external" clients in a split DNS setup.
6975           </p>
6976 <p>
6977             Many of the options given in the <span><strong class="command">options</strong></span> statement
6978             can also be used within a <span><strong class="command">view</strong></span>
6979             statement, and then
6980             apply only when resolving queries with that view.  When no
6981             view-specific
6982             value is given, the value in the <span><strong class="command">options</strong></span> statement
6983             is used as a default.  Also, zone options can have default values
6984             specified
6985             in the <span><strong class="command">view</strong></span> statement; these
6986             view-specific defaults
6987             take precedence over those in the <span><strong class="command">options</strong></span> statement.
6988           </p>
6989 <p>
6990             Views are class specific.  If no class is given, class IN
6991             is assumed.  Note that all non-IN views must contain a hint zone,
6992             since only the IN class has compiled-in default hints.
6993           </p>
6994 <p>
6995             If there are no <span><strong class="command">view</strong></span> statements in
6996             the config
6997             file, a default view that matches any client is automatically
6998             created
6999             in class IN. Any <span><strong class="command">zone</strong></span> statements
7000             specified on
7001             the top level of the configuration file are considered to be part
7002             of
7003             this default view, and the <span><strong class="command">options</strong></span>
7004             statement will
7005             apply to the default view. If any explicit <span><strong class="command">view</strong></span>
7006             statements are present, all <span><strong class="command">zone</strong></span>
7007             statements must
7008             occur inside <span><strong class="command">view</strong></span> statements.
7009           </p>
7010 <p>
7011             Here is an example of a typical split DNS setup implemented
7012             using <span><strong class="command">view</strong></span> statements:
7013           </p>
7014 <pre class="programlisting">view "internal" {
7015       // This should match our internal networks.
7016       match-clients { 10.0.0.0/8; };
7017
7018       // Provide recursive service to internal
7019       // clients only.
7020       recursion yes;
7021
7022       // Provide a complete view of the example.com
7023       // zone including addresses of internal hosts.
7024       zone "example.com" {
7025             type master;
7026             file "example-internal.db";
7027       };
7028 };
7029
7030 view "external" {
7031       // Match all clients not matched by the
7032       // previous view.
7033       match-clients { any; };
7034
7035       // Refuse recursive service to external clients.
7036       recursion no;
7037
7038       // Provide a restricted view of the example.com
7039       // zone containing only publicly accessible hosts.
7040       zone "example.com" {
7041            type master;
7042            file "example-external.db";
7043       };
7044 };
7045 </pre>
7046 </div>
7047 <div class="sect2" lang="en">
7048 <div class="titlepage"><div><div><h3 class="title">
7049 <a name="zone_statement_grammar"></a><span><strong class="command">zone</strong></span>
7050             Statement Grammar</h3></div></div></div>
7051 <pre class="programlisting"><span><strong class="command">zone</strong></span> <em class="replaceable"><code>zone_name</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
7052     type master;
7053     [<span class="optional"> allow-query { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7054     [<span class="optional"> allow-query-on { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7055     [<span class="optional"> allow-transfer { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7056     [<span class="optional"> allow-update { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7057     [<span class="optional"> update-check-ksk <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7058     [<span class="optional"> dnssec-dnskey-kskonly <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7059     [<span class="optional"> dnssec-loadkeys-interval <em class="replaceable"><code>number</code></em>; </span>]
7060     [<span class="optional"> update-policy <em class="replaceable"><code>local</code></em> | { <em class="replaceable"><code>update_policy_rule</code></em> [<span class="optional">...</span>] }; </span>]
7061     [<span class="optional"> also-notify { <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ;
7062                   [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; ... </span>] }; </span>]
7063     [<span class="optional"> check-names (<code class="constant">warn</code>|<code class="constant">fail</code>|<code class="constant">ignore</code>) ; </span>]
7064     [<span class="optional"> check-mx (<code class="constant">warn</code>|<code class="constant">fail</code>|<code class="constant">ignore</code>) ; </span>]
7065     [<span class="optional"> check-wildcard <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7066     [<span class="optional"> check-spf ( <em class="replaceable"><code>warn</code></em> | <em class="replaceable"><code>ignore</code></em> ); </span>]
7067     [<span class="optional"> check-integrity <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7068     [<span class="optional"> dialup <em class="replaceable"><code>dialup_option</code></em> ; </span>]
7069     [<span class="optional"> file <em class="replaceable"><code>string</code></em> ; </span>]
7070     [<span class="optional"> masterfile-format (<code class="constant">text</code>|<code class="constant">raw</code>) ; </span>]
7071     [<span class="optional"> journal <em class="replaceable"><code>string</code></em> ; </span>]
7072     [<span class="optional"> max-journal-size <em class="replaceable"><code>size_spec</code></em>; </span>]
7073     [<span class="optional"> forward (<code class="constant">only</code>|<code class="constant">first</code>) ; </span>]
7074     [<span class="optional"> forwarders { [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; ... </span>] }; </span>]
7075     [<span class="optional"> ixfr-base <em class="replaceable"><code>string</code></em> ; </span>]
7076     [<span class="optional"> ixfr-from-differences <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7077     [<span class="optional"> ixfr-tmp-file <em class="replaceable"><code>string</code></em> ; </span>]
7078     [<span class="optional"> request-ixfr <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7079     [<span class="optional"> maintain-ixfr-base <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7080     [<span class="optional"> max-ixfr-log-size <em class="replaceable"><code>number</code></em> ; </span>]
7081     [<span class="optional"> max-transfer-idle-out <em class="replaceable"><code>number</code></em> ; </span>]
7082     [<span class="optional"> max-transfer-time-out <em class="replaceable"><code>number</code></em> ; </span>]
7083     [<span class="optional"> notify <em class="replaceable"><code>yes_or_no</code></em> | <em class="replaceable"><code>explicit</code></em> | <em class="replaceable"><code>master-only</code></em> ; </span>]
7084     [<span class="optional"> notify-delay <em class="replaceable"><code>seconds</code></em> ; </span>]
7085     [<span class="optional"> notify-to-soa <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7086     [<span class="optional"> pubkey <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>string</code></em> ; </span>]
7087     [<span class="optional"> notify-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7088     [<span class="optional"> notify-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7089     [<span class="optional"> zone-statistics <em class="replaceable"><code>full</code></em> | <em class="replaceable"><code>terse</code></em> | <em class="replaceable"><code>none</code></em>; </span>]
7090     [<span class="optional"> sig-validity-interval <em class="replaceable"><code>number</code></em> [<span class="optional"><em class="replaceable"><code>number</code></em></span>] ; </span>]
7091     [<span class="optional"> sig-signing-nodes <em class="replaceable"><code>number</code></em> ; </span>]
7092     [<span class="optional"> sig-signing-signatures <em class="replaceable"><code>number</code></em> ; </span>]
7093     [<span class="optional"> sig-signing-type <em class="replaceable"><code>number</code></em> ; </span>]
7094     [<span class="optional"> database <em class="replaceable"><code>string</code></em> ; </span>]
7095     [<span class="optional"> min-refresh-time <em class="replaceable"><code>number</code></em> ; </span>]
7096     [<span class="optional"> max-refresh-time <em class="replaceable"><code>number</code></em> ; </span>]
7097     [<span class="optional"> min-retry-time <em class="replaceable"><code>number</code></em> ; </span>]
7098     [<span class="optional"> max-retry-time <em class="replaceable"><code>number</code></em> ; </span>]
7099     [<span class="optional"> key-directory <em class="replaceable"><code>path_name</code></em>; </span>]
7100     [<span class="optional"> auto-dnssec <code class="constant">allow</code>|<code class="constant">maintain</code>|<code class="constant">off</code>; </span>]
7101     [<span class="optional"> inline-signing <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7102     [<span class="optional"> zero-no-soa-ttl <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7103     [<span class="optional"> serial-update-method <code class="constant">increment</code>|<code class="constant">unixtime</code>; </span>]
7104 };
7105
7106 zone <em class="replaceable"><code>zone_name</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
7107     type slave;
7108     [<span class="optional"> allow-notify { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7109     [<span class="optional"> allow-query { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7110     [<span class="optional"> allow-query-on { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7111     [<span class="optional"> allow-transfer { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7112     [<span class="optional"> allow-update-forwarding { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7113     [<span class="optional"> dnssec-update-mode ( <em class="replaceable"><code>maintain</code></em> | <em class="replaceable"><code>no-resign</code></em> ); </span>]
7114     [<span class="optional"> update-check-ksk <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7115     [<span class="optional"> dnssec-dnskey-kskonly <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7116     [<span class="optional"> dnssec-loadkeys-interval <em class="replaceable"><code>number</code></em>; </span>]
7117     [<span class="optional"> dnssec-secure-to-insecure <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7118     [<span class="optional"> try-tcp-refresh <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7119     [<span class="optional"> also-notify [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] { ( <em class="replaceable"><code>masters_list</code></em> | <em class="replaceable"><code>ip_addr</code></em>
7120                               [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>]
7121                               [<span class="optional">key <em class="replaceable"><code>key</code></em></span>] ) ; [<span class="optional">...</span>] }; </span>]
7122     [<span class="optional"> check-names (<code class="constant">warn</code>|<code class="constant">fail</code>|<code class="constant">ignore</code>) ; </span>]
7123     [<span class="optional"> dialup <em class="replaceable"><code>dialup_option</code></em> ; </span>]
7124     [<span class="optional"> file <em class="replaceable"><code>string</code></em> ; </span>]
7125     [<span class="optional"> masterfile-format (<code class="constant">text</code>|<code class="constant">raw</code>) ; </span>]
7126     [<span class="optional"> journal <em class="replaceable"><code>string</code></em> ; </span>]
7127     [<span class="optional"> max-journal-size <em class="replaceable"><code>size_spec</code></em>; </span>]
7128     [<span class="optional"> forward (<code class="constant">only</code>|<code class="constant">first</code>) ; </span>]
7129     [<span class="optional"> forwarders { [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; ... </span>] }; </span>]
7130     [<span class="optional"> ixfr-base <em class="replaceable"><code>string</code></em> ; </span>]
7131     [<span class="optional"> ixfr-from-differences <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7132     [<span class="optional"> ixfr-tmp-file <em class="replaceable"><code>string</code></em> ; </span>]
7133     [<span class="optional"> maintain-ixfr-base <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7134     [<span class="optional"> masters [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] { ( <em class="replaceable"><code>masters_list</code></em> | <em class="replaceable"><code>ip_addr</code></em>
7135                               [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>]
7136                               [<span class="optional">key <em class="replaceable"><code>key</code></em></span>] ) ; [<span class="optional">...</span>] }; </span>]
7137     [<span class="optional"> max-ixfr-log-size <em class="replaceable"><code>number</code></em> ; </span>]
7138     [<span class="optional"> max-transfer-idle-in <em class="replaceable"><code>number</code></em> ; </span>]
7139     [<span class="optional"> max-transfer-idle-out <em class="replaceable"><code>number</code></em> ; </span>]
7140     [<span class="optional"> max-transfer-time-in <em class="replaceable"><code>number</code></em> ; </span>]
7141     [<span class="optional"> max-transfer-time-out <em class="replaceable"><code>number</code></em> ; </span>]
7142     [<span class="optional"> notify <em class="replaceable"><code>yes_or_no</code></em> | <em class="replaceable"><code>explicit</code></em> | <em class="replaceable"><code>master-only</code></em> ; </span>]
7143     [<span class="optional"> notify-delay <em class="replaceable"><code>seconds</code></em> ; </span>]
7144     [<span class="optional"> notify-to-soa <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7145     [<span class="optional"> pubkey <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>string</code></em> ; </span>]
7146     [<span class="optional"> transfer-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7147     [<span class="optional"> transfer-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7148     [<span class="optional"> alt-transfer-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7149     [<span class="optional"> alt-transfer-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>)
7150                              [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7151     [<span class="optional"> use-alt-transfer-source <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7152     [<span class="optional"> notify-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7153     [<span class="optional"> notify-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7154     [<span class="optional"> zone-statistics <em class="replaceable"><code>full</code></em> | <em class="replaceable"><code>terse</code></em> | <em class="replaceable"><code>none</code></em>; </span>]
7155     [<span class="optional"> sig-validity-interval <em class="replaceable"><code>number</code></em> [<span class="optional"><em class="replaceable"><code>number</code></em></span>] ; </span>]
7156     [<span class="optional"> sig-signing-nodes <em class="replaceable"><code>number</code></em> ; </span>]
7157     [<span class="optional"> sig-signing-signatures <em class="replaceable"><code>number</code></em> ; </span>]
7158     [<span class="optional"> sig-signing-type <em class="replaceable"><code>number</code></em> ; </span>]
7159     [<span class="optional"> database <em class="replaceable"><code>string</code></em> ; </span>]
7160     [<span class="optional"> min-refresh-time <em class="replaceable"><code>number</code></em> ; </span>]
7161     [<span class="optional"> max-refresh-time <em class="replaceable"><code>number</code></em> ; </span>]
7162     [<span class="optional"> min-retry-time <em class="replaceable"><code>number</code></em> ; </span>]
7163     [<span class="optional"> max-retry-time <em class="replaceable"><code>number</code></em> ; </span>]
7164     [<span class="optional"> key-directory <em class="replaceable"><code>path_name</code></em>; </span>]
7165     [<span class="optional"> auto-dnssec <code class="constant">allow</code>|<code class="constant">maintain</code>|<code class="constant">off</code>; </span>]
7166     [<span class="optional"> inline-signing <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7167     [<span class="optional"> multi-master <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7168     [<span class="optional"> zero-no-soa-ttl <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7169 };
7170
7171 zone <em class="replaceable"><code>zone_name</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
7172     type hint;
7173     file <em class="replaceable"><code>string</code></em> ;
7174     [<span class="optional"> delegation-only <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7175     [<span class="optional"> check-names (<code class="constant">warn</code>|<code class="constant">fail</code>|<code class="constant">ignore</code>) ; </span>] // Not Implemented.
7176 };
7177
7178 zone <em class="replaceable"><code>zone_name</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
7179     type stub;
7180     [<span class="optional"> allow-query { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7181     [<span class="optional"> allow-query-on { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7182     [<span class="optional"> check-names (<code class="constant">warn</code>|<code class="constant">fail</code>|<code class="constant">ignore</code>) ; </span>]
7183     [<span class="optional"> dialup <em class="replaceable"><code>dialup_option</code></em> ; </span>]
7184     [<span class="optional"> delegation-only <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7185     [<span class="optional"> file <em class="replaceable"><code>string</code></em> ; </span>]
7186     [<span class="optional"> masterfile-format (<code class="constant">text</code>|<code class="constant">raw</code>) ; </span>]
7187     [<span class="optional"> forward (<code class="constant">only</code>|<code class="constant">first</code>) ; </span>]
7188     [<span class="optional"> forwarders { [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; ... </span>] }; </span>]
7189     [<span class="optional"> masters [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] { ( <em class="replaceable"><code>masters_list</code></em> | <em class="replaceable"><code>ip_addr</code></em>
7190                               [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>]
7191                               [<span class="optional">key <em class="replaceable"><code>key</code></em></span>] ) ; [<span class="optional">...</span>] }; </span>]
7192     [<span class="optional"> max-transfer-idle-in <em class="replaceable"><code>number</code></em> ; </span>]
7193     [<span class="optional"> max-transfer-time-in <em class="replaceable"><code>number</code></em> ; </span>]
7194     [<span class="optional"> pubkey <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>number</code></em> <em class="replaceable"><code>string</code></em> ; </span>]
7195     [<span class="optional"> transfer-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7196     [<span class="optional"> transfer-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>)
7197                          [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7198     [<span class="optional"> alt-transfer-source (<em class="replaceable"><code>ip4_addr</code></em> | <code class="constant">*</code>) [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7199     [<span class="optional"> alt-transfer-source-v6 (<em class="replaceable"><code>ip6_addr</code></em> | <code class="constant">*</code>)
7200                             [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; </span>]
7201     [<span class="optional"> use-alt-transfer-source <em class="replaceable"><code>yes_or_no</code></em>; </span>]
7202     [<span class="optional"> zone-statistics <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7203     [<span class="optional"> database <em class="replaceable"><code>string</code></em> ; </span>]
7204     [<span class="optional"> min-refresh-time <em class="replaceable"><code>number</code></em> ; </span>]
7205     [<span class="optional"> max-refresh-time <em class="replaceable"><code>number</code></em> ; </span>]
7206     [<span class="optional"> min-retry-time <em class="replaceable"><code>number</code></em> ; </span>]
7207     [<span class="optional"> max-retry-time <em class="replaceable"><code>number</code></em> ; </span>]
7208     [<span class="optional"> multi-master <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7209 };
7210
7211 zone <em class="replaceable"><code>zone_name</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
7212     type static-stub;
7213     [<span class="optional"> allow-query { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7214     [<span class="optional"> server-addresses { [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> ; ... </span>] }; </span>]
7215     [<span class="optional"> server-names { [<span class="optional"> <em class="replaceable"><code>namelist</code></em> </span>] }; </span>]  
7216     [<span class="optional"> zone-statistics <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7217 };
7218
7219 zone <em class="replaceable"><code>zone_name</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
7220     type forward;
7221     [<span class="optional"> forward (<code class="constant">only</code>|<code class="constant">first</code>) ; </span>]
7222     [<span class="optional"> forwarders { [<span class="optional"> <em class="replaceable"><code>ip_addr</code></em> [<span class="optional">port <em class="replaceable"><code>ip_port</code></em></span>] ; ... </span>] }; </span>]
7223     [<span class="optional"> delegation-only <em class="replaceable"><code>yes_or_no</code></em> ; </span>]
7224 };
7225
7226 zone <em class="replaceable"><code>"."</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
7227     type redirect;
7228     file <em class="replaceable"><code>string</code></em> ;
7229     [<span class="optional"> masterfile-format (<code class="constant">text</code>|<code class="constant">raw</code>) ; </span>]
7230     [<span class="optional"> allow-query { <em class="replaceable"><code>address_match_list</code></em> }; </span>]
7231 };
7232
7233 zone <em class="replaceable"><code>zone_name</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em></span>] {
7234     type delegation-only;
7235 };
7236
7237 </pre>
7238 </div>
7239 <div class="sect2" lang="en">
7240 <div class="titlepage"><div><div><h3 class="title">
7241 <a name="id2592987"></a><span><strong class="command">zone</strong></span> Statement Definition and Usage</h3></div></div></div>
7242 <div class="sect3" lang="en">
7243 <div class="titlepage"><div><div><h4 class="title">
7244 <a name="id2592995"></a>Zone Types</h4></div></div></div>
7245 <div class="informaltable"><table border="1">
7246 <colgroup>
7247 <col>
7248 <col>
7249 </colgroup>
7250 <tbody>
7251 <tr>
7252 <td>
7253                       <p>
7254                         <code class="varname">master</code>
7255                       </p>
7256                     </td>
7257 <td>
7258                       <p>
7259                         The server has a master copy of the data
7260                         for the zone and will be able to provide authoritative
7261                         answers for
7262                         it.
7263                       </p>
7264                     </td>
7265 </tr>
7266 <tr>
7267 <td>
7268                       <p>
7269                         <code class="varname">slave</code>
7270                       </p>
7271                     </td>
7272 <td>
7273                       <p>
7274                         A slave zone is a replica of a master
7275                         zone. The <span><strong class="command">masters</strong></span> list
7276                         specifies one or more IP addresses
7277                         of master servers that the slave contacts to update
7278                         its copy of the zone.
7279                         Masters list elements can also be names of other
7280                         masters lists.
7281                         By default, transfers are made from port 53 on the
7282                         servers; this can
7283                         be changed for all servers by specifying a port number
7284                         before the
7285                         list of IP addresses, or on a per-server basis after
7286                         the IP address.
7287                         Authentication to the master can also be done with
7288                         per-server TSIG keys.
7289                         If a file is specified, then the
7290                         replica will be written to this file whenever the zone
7291                         is changed,
7292                         and reloaded from this file on a server restart. Use
7293                         of a file is
7294                         recommended, since it often speeds server startup and
7295                         eliminates
7296                         a needless waste of bandwidth. Note that for large
7297                         numbers (in the
7298                         tens or hundreds of thousands) of zones per server, it
7299                         is best to
7300                         use a two-level naming scheme for zone filenames. For
7301                         example,
7302                         a slave server for the zone <code class="literal">example.com</code> might place
7303                         the zone contents into a file called
7304                         <code class="filename">ex/example.com</code> where <code class="filename">ex/</code> is
7305                         just the first two letters of the zone name. (Most
7306                         operating systems
7307                         behave very slowly if you put 100000 files into
7308                         a single directory.)
7309                       </p>
7310                     </td>
7311 </tr>
7312 <tr>
7313 <td>
7314                       <p>
7315                         <code class="varname">stub</code>
7316                       </p>
7317                     </td>
7318 <td>
7319                       <p>
7320                         A stub zone is similar to a slave zone,
7321                         except that it replicates only the NS records of a
7322                         master zone instead
7323                         of the entire zone. Stub zones are not a standard part
7324                         of the DNS;
7325                         they are a feature specific to the <acronym class="acronym">BIND</acronym> implementation.
7326                       </p>
7327
7328                       <p>
7329                         Stub zones can be used to eliminate the need for glue
7330                         NS record
7331                         in a parent zone at the expense of maintaining a stub
7332                         zone entry and
7333                         a set of name server addresses in <code class="filename">named.conf</code>.
7334                         This usage is not recommended for new configurations,
7335                         and BIND 9
7336                         supports it only in a limited way.
7337                         In <acronym class="acronym">BIND</acronym> 4/8, zone
7338                         transfers of a parent zone
7339                         included the NS records from stub children of that
7340                         zone. This meant
7341                         that, in some cases, users could get away with
7342                         configuring child stubs
7343                         only in the master server for the parent zone. <acronym class="acronym">BIND</acronym>
7344                         9 never mixes together zone data from different zones
7345                         in this
7346                         way. Therefore, if a <acronym class="acronym">BIND</acronym> 9 master serving a parent
7347                         zone has child stub zones configured, all the slave
7348                         servers for the
7349                         parent zone also need to have the same child stub
7350                         zones
7351                         configured.
7352                       </p>
7353
7354                       <p>
7355                         Stub zones can also be used as a way of forcing the
7356                         resolution
7357                         of a given domain to use a particular set of
7358                         authoritative servers.
7359                         For example, the caching name servers on a private
7360                         network using
7361                         RFC1918 addressing may be configured with stub zones
7362                         for
7363                         <code class="literal">10.in-addr.arpa</code>
7364                         to use a set of internal name servers as the
7365                         authoritative
7366                         servers for that domain.
7367                       </p>
7368                     </td>
7369 </tr>
7370 <tr>
7371 <td>
7372                       <p>
7373                         <code class="varname">static-stub</code>
7374                       </p>
7375                     </td>
7376 <td>
7377                       <p>
7378                         A static-stub zone is similar to a stub zone
7379                         with the following exceptions:
7380                         the zone data is statically configured, rather
7381                         than transferred from a master server;
7382                         when recursion is necessary for a query that
7383                         matches a static-stub zone, the locally
7384                         configured data (nameserver names and glue addresses)
7385                         is always used even if different authoritative
7386                         information is cached.
7387                       </p>
7388                       <p>
7389                         Zone data is configured via the
7390                         <span><strong class="command">server-addresses</strong></span> and
7391                         <span><strong class="command">server-names</strong></span> zone options.
7392                       </p>
7393                       <p>
7394                         The zone data is maintained in the form of NS
7395                         and (if necessary) glue A or AAAA RRs
7396                         internally, which can be seen by dumping zone
7397                         databases by <span><strong class="command">rndc dumpdb -all</strong></span>.
7398                         The configured RRs are considered local configuration
7399                         parameters rather than public data.
7400                         Non recursive queries (i.e., those with the RD
7401                         bit off) to a static-stub zone are therefore
7402                         prohibited and will be responded with REFUSED.
7403                       </p>
7404                       <p>
7405                         Since the data is statically configured, no
7406                         zone maintenance action takes place for a static-stub
7407                         zone.
7408                         For example, there is no periodic refresh
7409                         attempt, and an incoming notify message
7410                         will be rejected with an rcode of NOTAUTH.
7411                       </p>
7412                       <p>
7413                         Each static-stub zone is configured with
7414                         internally generated NS and (if necessary)
7415                         glue A or AAAA RRs 
7416                       </p>
7417                     </td>
7418 </tr>
7419 <tr>
7420 <td>
7421                       <p>
7422                         <code class="varname">forward</code>
7423                       </p>
7424                     </td>
7425 <td>
7426                       <p>
7427                         A "forward zone" is a way to configure
7428                         forwarding on a per-domain basis.  A <span><strong class="command">zone</strong></span> statement
7429                         of type <span><strong class="command">forward</strong></span> can
7430                         contain a <span><strong class="command">forward</strong></span>
7431                         and/or <span><strong class="command">forwarders</strong></span>
7432                         statement,
7433                         which will apply to queries within the domain given by
7434                         the zone
7435                         name. If no <span><strong class="command">forwarders</strong></span>
7436                         statement is present or
7437                         an empty list for <span><strong class="command">forwarders</strong></span> is given, then no
7438                         forwarding will be done for the domain, canceling the
7439                         effects of
7440                         any forwarders in the <span><strong class="command">options</strong></span> statement. Thus
7441                         if you want to use this type of zone to change the
7442                         behavior of the
7443                         global <span><strong class="command">forward</strong></span> option
7444                         (that is, "forward first"
7445                         to, then "forward only", or vice versa, but want to
7446                         use the same
7447                         servers as set globally) you need to re-specify the
7448                         global forwarders.
7449                       </p>
7450                     </td>
7451 </tr>
7452 <tr>
7453 <td>
7454                       <p>
7455                         <code class="varname">hint</code>
7456                       </p>
7457                     </td>
7458 <td>
7459                       <p>
7460                         The initial set of root name servers is
7461                         specified using a "hint zone". When the server starts
7462                         up, it uses
7463                         the root hints to find a root name server and get the
7464                         most recent
7465                         list of root name servers. If no hint zone is
7466                         specified for class
7467                         IN, the server uses a compiled-in default set of root
7468                         servers hints.
7469                         Classes other than IN have no built-in defaults hints.
7470                       </p>
7471                     </td>
7472 </tr>
7473 <tr>
7474 <td>
7475                       <p>
7476                         <code class="varname">redirect</code>
7477                       </p>
7478                     </td>
7479 <td>
7480                       <p>
7481                         Redirect zones are used to provide answers to
7482                         queries when normal resolution would result in
7483                         NXDOMAIN being returned.
7484                         Only one redirect zone is supported
7485                         per view.  <span><strong class="command">allow-query</strong></span> can be
7486                         used to restrict which clients see these answers.
7487                       </p>
7488                       <p>
7489                         If the client has requested DNSSEC records (DO=1) and
7490                         the NXDOMAIN response is signed then no substitution
7491                         will occur.
7492                       </p>
7493                       <p>
7494                         To redirect all NXDOMAIN responses to
7495                         100.100.100.2 and
7496                         2001:ffff:ffff::100.100.100.2, one would
7497                         configure a type redirect zone named ".",
7498                         with the zone file containing wildcard records
7499                         that point to the desired addresses: 
7500                         <code class="literal">"*. IN A 100.100.100.2"</code>
7501                         and
7502                         <code class="literal">"*. IN AAAA 2001:ffff:ffff::100.100.100.2"</code>.
7503                       </p>
7504                       <p>
7505                         To redirect all Spanish names (under .ES) one
7506                         would use similar entries but with the names
7507                         "*.ES." instead of "*.".  To redirect all 
7508                         commercial Spanish names (under COM.ES) one
7509                         would use wildcard entries called "*.COM.ES.".
7510                       </p>
7511                       <p>
7512                         Note that the redirect zone supports all
7513                         possible types; it is not limited to A and
7514                         AAAA records.
7515                       </p>
7516                       <p>
7517                         Because redirect zones are not referenced
7518                         directly by name, they are not kept in the
7519                         zone lookup table with normal master and slave
7520                         zones. Consequently, it is not currently possible
7521                         to use
7522                         <span><strong class="command">rndc reload
7523                                 <em class="replaceable"><code>zonename</code></em></strong></span>
7524                         to reload a redirect zone.  However, when using
7525                         <span><strong class="command">rndc reload</strong></span> without specifying
7526                         a zone name, redirect zones will be reloaded along
7527                         with other zones.
7528                       </p>
7529                     </td>
7530 </tr>
7531 <tr>
7532 <td>
7533                       <p>
7534                         <code class="varname">delegation-only</code>
7535                       </p>
7536                     </td>
7537 <td>
7538                       <p>
7539                         This is used to enforce the delegation-only
7540                         status of infrastructure zones (e.g. COM,
7541                         NET, ORG).  Any answer that is received
7542                         without an explicit or implicit delegation
7543                         in the authority section will be treated
7544                         as NXDOMAIN.  This does not apply to the
7545                         zone apex.  This should not be applied to
7546                         leaf zones.
7547                       </p>
7548                       <p>
7549                         <code class="varname">delegation-only</code> has no
7550                         effect on answers received from forwarders.
7551                       </p>
7552                       <p>
7553                         See caveats in <a href="Bv9ARM.ch06.html#root_delegation_only"><span><strong class="command">root-delegation-only</strong></span></a>.
7554                       </p>
7555                     </td>
7556 </tr>
7557 </tbody>
7558 </table></div>
7559 </div>
7560 <div class="sect3" lang="en">
7561 <div class="titlepage"><div><div><h4 class="title">
7562 <a name="id2593739"></a>Class</h4></div></div></div>
7563 <p>
7564               The zone's name may optionally be followed by a class. If
7565               a class is not specified, class <code class="literal">IN</code> (for <code class="varname">Internet</code>),
7566               is assumed. This is correct for the vast majority of cases.
7567             </p>
7568 <p>
7569               The <code class="literal">hesiod</code> class is
7570               named for an information service from MIT's Project Athena. It
7571               is
7572               used to share information about various systems databases, such
7573               as users, groups, printers and so on. The keyword
7574               <code class="literal">HS</code> is
7575               a synonym for hesiod.
7576             </p>
7577 <p>
7578               Another MIT development is Chaosnet, a LAN protocol created
7579               in the mid-1970s. Zone data for it can be specified with the <code class="literal">CHAOS</code> class.
7580             </p>
7581 </div>
7582 <div class="sect3" lang="en">
7583 <div class="titlepage"><div><div><h4 class="title">
7584 <a name="id2593772"></a>Zone Options</h4></div></div></div>
7585 <div class="variablelist"><dl>
7586 <dt><span class="term"><span><strong class="command">allow-notify</strong></span></span></dt>
7587 <dd><p>
7588                     See the description of
7589                     <span><strong class="command">allow-notify</strong></span> in <a href="Bv9ARM.ch06.html#access_control" title="Access Control">the section called &#8220;Access Control&#8221;</a>.
7590                   </p></dd>
7591 <dt><span class="term"><span><strong class="command">allow-query</strong></span></span></dt>
7592 <dd><p>
7593                     See the description of
7594                     <span><strong class="command">allow-query</strong></span> in <a href="Bv9ARM.ch06.html#access_control" title="Access Control">the section called &#8220;Access Control&#8221;</a>.
7595                   </p></dd>
7596 <dt><span class="term"><span><strong class="command">allow-query-on</strong></span></span></dt>
7597 <dd><p>
7598                     See the description of
7599                     <span><strong class="command">allow-query-on</strong></span> in <a href="Bv9ARM.ch06.html#access_control" title="Access Control">the section called &#8220;Access Control&#8221;</a>.
7600                   </p></dd>
7601 <dt><span class="term"><span><strong class="command">allow-transfer</strong></span></span></dt>
7602 <dd><p>
7603                     See the description of <span><strong class="command">allow-transfer</strong></span>
7604                     in <a href="Bv9ARM.ch06.html#access_control" title="Access Control">the section called &#8220;Access Control&#8221;</a>.
7605                   </p></dd>
7606 <dt><span class="term"><span><strong class="command">allow-update</strong></span></span></dt>
7607 <dd><p>
7608                     See the description of <span><strong class="command">allow-update</strong></span>
7609                     in <a href="Bv9ARM.ch06.html#access_control" title="Access Control">the section called &#8220;Access Control&#8221;</a>.
7610                   </p></dd>
7611 <dt><span class="term"><span><strong class="command">update-policy</strong></span></span></dt>
7612 <dd><p>
7613                     Specifies a "Simple Secure Update" policy. See
7614                     <a href="Bv9ARM.ch06.html#dynamic_update_policies" title="Dynamic Update Policies">the section called &#8220;Dynamic Update Policies&#8221;</a>.
7615                   </p></dd>
7616 <dt><span class="term"><span><strong class="command">allow-update-forwarding</strong></span></span></dt>
7617 <dd><p>
7618                     See the description of <span><strong class="command">allow-update-forwarding</strong></span>
7619                     in <a href="Bv9ARM.ch06.html#access_control" title="Access Control">the section called &#8220;Access Control&#8221;</a>.
7620                   </p></dd>
7621 <dt><span class="term"><span><strong class="command">also-notify</strong></span></span></dt>
7622 <dd><p>
7623                     Only meaningful if <span><strong class="command">notify</strong></span>
7624                     is
7625                     active for this zone. The set of machines that will
7626                     receive a
7627                     <code class="literal">DNS NOTIFY</code> message
7628                     for this zone is made up of all the listed name servers
7629                     (other than
7630                     the primary master) for the zone plus any IP addresses
7631                     specified
7632                     with <span><strong class="command">also-notify</strong></span>. A port
7633                     may be specified
7634                     with each <span><strong class="command">also-notify</strong></span>
7635                     address to send the notify
7636                     messages to a port other than the default of 53.
7637                     A TSIG key may also be specified to cause the
7638                     <code class="literal">NOTIFY</code> to be signed by the
7639                     given key.
7640                     <span><strong class="command">also-notify</strong></span> is not
7641                     meaningful for stub zones.
7642                     The default is the empty list.
7643                   </p></dd>
7644 <dt><span class="term"><span><strong class="command">check-names</strong></span></span></dt>
7645 <dd><p>
7646                     This option is used to restrict the character set and
7647                     syntax of
7648                     certain domain names in master files and/or DNS responses
7649                     received from the
7650                     network.  The default varies according to zone type.  For <span><strong class="command">master</strong></span> zones the default is <span><strong class="command">fail</strong></span>.  For <span><strong class="command">slave</strong></span>
7651                     zones the default is <span><strong class="command">warn</strong></span>.
7652                     It is not implemented for <span><strong class="command">hint</strong></span> zones.
7653                   </p></dd>
7654 <dt><span class="term"><span><strong class="command">check-mx</strong></span></span></dt>
7655 <dd><p>
7656                     See the description of
7657                     <span><strong class="command">check-mx</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7658                   </p></dd>
7659 <dt><span class="term"><span><strong class="command">check-spf</strong></span></span></dt>
7660 <dd><p>
7661                     See the description of
7662                     <span><strong class="command">check-spf</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7663                   </p></dd>
7664 <dt><span class="term"><span><strong class="command">check-wildcard</strong></span></span></dt>
7665 <dd><p>
7666                     See the description of
7667                     <span><strong class="command">check-wildcard</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7668                   </p></dd>
7669 <dt><span class="term"><span><strong class="command">check-integrity</strong></span></span></dt>
7670 <dd><p>
7671                     See the description of
7672                     <span><strong class="command">check-integrity</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7673                   </p></dd>
7674 <dt><span class="term"><span><strong class="command">check-sibling</strong></span></span></dt>
7675 <dd><p>
7676                     See the description of
7677                     <span><strong class="command">check-sibling</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7678                   </p></dd>
7679 <dt><span class="term"><span><strong class="command">zero-no-soa-ttl</strong></span></span></dt>
7680 <dd><p>
7681                     See the description of
7682                     <span><strong class="command">zero-no-soa-ttl</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7683                   </p></dd>
7684 <dt><span class="term"><span><strong class="command">update-check-ksk</strong></span></span></dt>
7685 <dd><p>
7686                     See the description of
7687                     <span><strong class="command">update-check-ksk</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7688                   </p></dd>
7689 <dt><span class="term"><span><strong class="command">dnssec-update-mode</strong></span></span></dt>
7690 <dd><p>
7691                     See the description of
7692                     <span><strong class="command">dnssec-update-mode</strong></span> in <a href="Bv9ARM.ch06.html#options" title="options Statement Definition and
7693           Usage">the section called &#8220;<span><strong class="command">options</strong></span> Statement Definition and
7694           Usage&#8221;</a>.
7695                   </p></dd>
7696 <dt><span class="term"><span><strong class="command">dnssec-dnskey-kskonly</strong></span></span></dt>
7697 <dd><p>
7698                     See the description of
7699                     <span><strong class="command">dnssec-dnskey-kskonly</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7700                   </p></dd>
7701 <dt><span class="term"><span><strong class="command">try-tcp-refresh</strong></span></span></dt>
7702 <dd><p>
7703                     See the description of
7704                     <span><strong class="command">try-tcp-refresh</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7705                   </p></dd>
7706 <dt><span class="term"><span><strong class="command">database</strong></span></span></dt>
7707 <dd>
7708 <p>
7709                     Specify the type of database to be used for storing the
7710                     zone data.  The string following the <span><strong class="command">database</strong></span> keyword
7711                     is interpreted as a list of whitespace-delimited words.
7712                     The first word
7713                     identifies the database type, and any subsequent words are
7714                     passed
7715                     as arguments to the database to be interpreted in a way
7716                     specific
7717                     to the database type.
7718                   </p>
7719 <p>
7720                     The default is <strong class="userinput"><code>"rbt"</code></strong>, BIND 9's
7721                     native in-memory
7722                     red-black-tree database.  This database does not take
7723                     arguments.
7724                   </p>
7725 <p>
7726                     Other values are possible if additional database drivers
7727                     have been linked into the server.  Some sample drivers are
7728                     included
7729                     with the distribution but none are linked in by default.
7730                   </p>
7731 </dd>
7732 <dt><span class="term"><span><strong class="command">dialup</strong></span></span></dt>
7733 <dd><p>
7734                     See the description of
7735                     <span><strong class="command">dialup</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7736                   </p></dd>
7737 <dt><span class="term"><span><strong class="command">delegation-only</strong></span></span></dt>
7738 <dd>
7739 <p>
7740                     The flag only applies to forward, hint and stub
7741                     zones.  If set to <strong class="userinput"><code>yes</code></strong>,
7742                     then the zone will also be treated as if it is
7743                     also a delegation-only type zone.
7744                   </p>
7745 <p>
7746                     See caveats in <a href="Bv9ARM.ch06.html#root_delegation_only"><span><strong class="command">root-delegation-only</strong></span></a>.
7747                   </p>
7748 </dd>
7749 <dt><span class="term"><span><strong class="command">forward</strong></span></span></dt>
7750 <dd><p>
7751                     Only meaningful if the zone has a forwarders
7752                     list. The <span><strong class="command">only</strong></span> value causes
7753                     the lookup to fail
7754                     after trying the forwarders and getting no answer, while <span><strong class="command">first</strong></span> would
7755                     allow a normal lookup to be tried.
7756                   </p></dd>
7757 <dt><span class="term"><span><strong class="command">forwarders</strong></span></span></dt>
7758 <dd><p>
7759                     Used to override the list of global forwarders.
7760                     If it is not specified in a zone of type <span><strong class="command">forward</strong></span>,
7761                     no forwarding is done for the zone and the global options are
7762                     not used.
7763                   </p></dd>
7764 <dt><span class="term"><span><strong class="command">ixfr-base</strong></span></span></dt>
7765 <dd><p>
7766                     Was used in <acronym class="acronym">BIND</acronym> 8 to
7767                     specify the name
7768                     of the transaction log (journal) file for dynamic update
7769                     and IXFR.
7770                     <acronym class="acronym">BIND</acronym> 9 ignores the option
7771                     and constructs the name of the journal
7772                     file by appending "<code class="filename">.jnl</code>"
7773                     to the name of the
7774                     zone file.
7775                   </p></dd>
7776 <dt><span class="term"><span><strong class="command">ixfr-tmp-file</strong></span></span></dt>
7777 <dd><p>
7778                     Was an undocumented option in <acronym class="acronym">BIND</acronym> 8.
7779                     Ignored in <acronym class="acronym">BIND</acronym> 9.
7780                   </p></dd>
7781 <dt><span class="term"><span><strong class="command">journal</strong></span></span></dt>
7782 <dd><p>
7783                     Allow the default journal's filename to be overridden.
7784                     The default is the zone's filename with "<code class="filename">.jnl</code>" appended.
7785                     This is applicable to <span><strong class="command">master</strong></span> and <span><strong class="command">slave</strong></span> zones.
7786                   </p></dd>
7787 <dt><span class="term"><span><strong class="command">max-journal-size</strong></span></span></dt>
7788 <dd><p>
7789                     See the description of
7790                     <span><strong class="command">max-journal-size</strong></span> in <a href="Bv9ARM.ch06.html#server_resource_limits" title="Server  Resource Limits">the section called &#8220;Server  Resource Limits&#8221;</a>.
7791                   </p></dd>
7792 <dt><span class="term"><span><strong class="command">max-transfer-time-in</strong></span></span></dt>
7793 <dd><p>
7794                     See the description of
7795                     <span><strong class="command">max-transfer-time-in</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7796                   </p></dd>
7797 <dt><span class="term"><span><strong class="command">max-transfer-idle-in</strong></span></span></dt>
7798 <dd><p>
7799                     See the description of
7800                     <span><strong class="command">max-transfer-idle-in</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7801                   </p></dd>
7802 <dt><span class="term"><span><strong class="command">max-transfer-time-out</strong></span></span></dt>
7803 <dd><p>
7804                     See the description of
7805                     <span><strong class="command">max-transfer-time-out</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7806                   </p></dd>
7807 <dt><span class="term"><span><strong class="command">max-transfer-idle-out</strong></span></span></dt>
7808 <dd><p>
7809                     See the description of
7810                     <span><strong class="command">max-transfer-idle-out</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7811                   </p></dd>
7812 <dt><span class="term"><span><strong class="command">notify</strong></span></span></dt>
7813 <dd><p>
7814                     See the description of
7815                     <span><strong class="command">notify</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7816                   </p></dd>
7817 <dt><span class="term"><span><strong class="command">notify-delay</strong></span></span></dt>
7818 <dd><p>
7819                     See the description of
7820                     <span><strong class="command">notify-delay</strong></span> in <a href="Bv9ARM.ch06.html#tuning" title="Tuning">the section called &#8220;Tuning&#8221;</a>.
7821                   </p></dd>
7822 <dt><span class="term"><span><strong class="command">notify-to-soa</strong></span></span></dt>
7823 <dd><p>
7824                     See the description of
7825                     <span><strong class="command">notify-to-soa</strong></span> in
7826                     <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7827                   </p></dd>
7828 <dt><span class="term"><span><strong class="command">pubkey</strong></span></span></dt>
7829 <dd><p>
7830                     In <acronym class="acronym">BIND</acronym> 8, this option was
7831                     intended for specifying
7832                     a public zone key for verification of signatures in DNSSEC
7833                     signed
7834                     zones when they are loaded from disk. <acronym class="acronym">BIND</acronym> 9 does not verify signatures
7835                     on load and ignores the option.
7836                   </p></dd>
7837 <dt><span class="term"><span><strong class="command">zone-statistics</strong></span></span></dt>
7838 <dd><p>
7839                     If <strong class="userinput"><code>yes</code></strong>, the server will keep
7840                     statistical
7841                     information for this zone, which can be dumped to the
7842                     <span><strong class="command">statistics-file</strong></span> defined in
7843                     the server options.
7844                   </p></dd>
7845 <dt><span class="term"><span><strong class="command">server-addresses</strong></span></span></dt>
7846 <dd>
7847 <p>
7848                     Only meaningful for static-stub zones.
7849                     This is a list of IP addresses to which queries
7850                     should be sent in recursive resolution for the
7851                     zone.
7852                     A non empty list for this option will internally
7853                     configure the apex NS RR with associated glue A or
7854                     AAAA RRs.
7855                   </p>
7856 <p>
7857                     For example, if "example.com" is configured as a
7858                     static-stub zone with 192.0.2.1 and 2001:db8::1234
7859                     in a <span><strong class="command">server-addresses</strong></span> option,
7860                     the following RRs will be internally configured.
7861                   </p>
7862 <pre class="programlisting">example.com. NS example.com.
7863 example.com. A 192.0.2.1
7864 example.com. AAAA 2001:db8::1234</pre>
7865 <p>
7866                     These records are internally used to resolve
7867                     names under the static-stub zone.
7868                     For instance, if the server receives a query for
7869                     "www.example.com" with the RD bit on, the server
7870                     will initiate recursive resolution and send
7871                     queries to 192.0.2.1 and/or 2001:db8::1234.
7872                   </p>
7873 </dd>
7874 <dt><span class="term"><span><strong class="command">server-names</strong></span></span></dt>
7875 <dd>
7876 <p>
7877                     Only meaningful for static-stub zones.
7878                     This is a list of domain names of nameservers that
7879                     act as authoritative servers of the static-stub
7880                     zone.
7881                     These names will be resolved to IP addresses when
7882                     <span><strong class="command">named</strong></span> needs to send queries to
7883                     these servers.
7884                     To make this supplemental resolution successful,
7885                     these names must not be a subdomain of the origin
7886                     name of static-stub zone.
7887                     That is, when "example.net" is the origin of a
7888                     static-stub zone, "ns.example" and
7889                     "master.example.com" can be specified in the
7890                     <span><strong class="command">server-names</strong></span> option, but
7891                     "ns.example.net" cannot, and will be rejected by
7892                     the configuration parser.
7893                   </p>
7894 <p>
7895                     A non empty list for this option will internally
7896                     configure the apex NS RR with the specified names.
7897                     For example, if "example.com" is configured as a
7898                     static-stub zone with "ns1.example.net" and
7899                     "ns2.example.net"
7900                     in a <span><strong class="command">server-names</strong></span> option,
7901                     the following RRs will be internally configured.
7902                   </p>
7903 <pre class="programlisting">example.com. NS ns1.example.net.
7904 example.com. NS ns2.example.net.
7905 </pre>
7906 <p>
7907                     These records are internally used to resolve
7908                     names under the static-stub zone.
7909                     For instance, if the server receives a query for
7910                     "www.example.com" with the RD bit on, the server
7911                     initiate recursive resolution,
7912                     resolve "ns1.example.net" and/or
7913                     "ns2.example.net" to IP addresses, and then send
7914                     queries to (one or more of) these addresses.
7915                   </p>
7916 </dd>
7917 <dt><span class="term"><span><strong class="command">sig-validity-interval</strong></span></span></dt>
7918 <dd><p>
7919                     See the description of
7920                     <span><strong class="command">sig-validity-interval</strong></span> in <a href="Bv9ARM.ch06.html#tuning" title="Tuning">the section called &#8220;Tuning&#8221;</a>.
7921                   </p></dd>
7922 <dt><span class="term"><span><strong class="command">sig-signing-nodes</strong></span></span></dt>
7923 <dd><p>
7924                     See the description of
7925                     <span><strong class="command">sig-signing-nodes</strong></span> in <a href="Bv9ARM.ch06.html#tuning" title="Tuning">the section called &#8220;Tuning&#8221;</a>.
7926                   </p></dd>
7927 <dt><span class="term"><span><strong class="command">sig-signing-signatures</strong></span></span></dt>
7928 <dd><p>
7929                     See the description of
7930                     <span><strong class="command">sig-signing-signatures</strong></span> in <a href="Bv9ARM.ch06.html#tuning" title="Tuning">the section called &#8220;Tuning&#8221;</a>.
7931                   </p></dd>
7932 <dt><span class="term"><span><strong class="command">sig-signing-type</strong></span></span></dt>
7933 <dd><p>
7934                     See the description of
7935                     <span><strong class="command">sig-signing-type</strong></span> in <a href="Bv9ARM.ch06.html#tuning" title="Tuning">the section called &#8220;Tuning&#8221;</a>.
7936                   </p></dd>
7937 <dt><span class="term"><span><strong class="command">transfer-source</strong></span></span></dt>
7938 <dd><p>
7939                     See the description of
7940                     <span><strong class="command">transfer-source</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7941                   </p></dd>
7942 <dt><span class="term"><span><strong class="command">transfer-source-v6</strong></span></span></dt>
7943 <dd><p>
7944                     See the description of
7945                     <span><strong class="command">transfer-source-v6</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7946                   </p></dd>
7947 <dt><span class="term"><span><strong class="command">alt-transfer-source</strong></span></span></dt>
7948 <dd><p>
7949                     See the description of
7950                     <span><strong class="command">alt-transfer-source</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7951                   </p></dd>
7952 <dt><span class="term"><span><strong class="command">alt-transfer-source-v6</strong></span></span></dt>
7953 <dd><p>
7954                     See the description of
7955                     <span><strong class="command">alt-transfer-source-v6</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7956                   </p></dd>
7957 <dt><span class="term"><span><strong class="command">use-alt-transfer-source</strong></span></span></dt>
7958 <dd><p>
7959                     See the description of
7960                     <span><strong class="command">use-alt-transfer-source</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7961                   </p></dd>
7962 <dt><span class="term"><span><strong class="command">notify-source</strong></span></span></dt>
7963 <dd><p>
7964                     See the description of
7965                     <span><strong class="command">notify-source</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7966                   </p></dd>
7967 <dt><span class="term"><span><strong class="command">notify-source-v6</strong></span></span></dt>
7968 <dd><p>
7969                     See the description of
7970                     <span><strong class="command">notify-source-v6</strong></span> in <a href="Bv9ARM.ch06.html#zone_transfers" title="Zone Transfers">the section called &#8220;Zone Transfers&#8221;</a>.
7971                   </p></dd>
7972 <dt>
7973 <span class="term"><span><strong class="command">min-refresh-time</strong></span>, </span><span class="term"><span><strong class="command">max-refresh-time</strong></span>, </span><span class="term"><span><strong class="command">min-retry-time</strong></span>, </span><span class="term"><span><strong class="command">max-retry-time</strong></span></span>
7974 </dt>
7975 <dd><p>
7976                     See the description in <a href="Bv9ARM.ch06.html#tuning" title="Tuning">the section called &#8220;Tuning&#8221;</a>.
7977                   </p></dd>
7978 <dt><span class="term"><span><strong class="command">ixfr-from-differences</strong></span></span></dt>
7979 <dd><p>
7980                     See the description of
7981                     <span><strong class="command">ixfr-from-differences</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
7982                     (Note that the <span><strong class="command">ixfr-from-differences</strong></span>
7983                     <strong class="userinput"><code>master</code></strong> and
7984                     <strong class="userinput"><code>slave</code></strong> choices are not
7985                     available at the zone level.)
7986                   </p></dd>
7987 <dt><span class="term"><span><strong class="command">key-directory</strong></span></span></dt>
7988 <dd><p>
7989                     See the description of
7990                     <span><strong class="command">key-directory</strong></span> in <a href="Bv9ARM.ch06.html#options" title="options Statement Definition and
7991           Usage">the section called &#8220;<span><strong class="command">options</strong></span> Statement Definition and
7992           Usage&#8221;</a>.
7993                   </p></dd>
7994 <dt><span class="term"><span><strong class="command">auto-dnssec</strong></span></span></dt>
7995 <dd>
7996 <p>
7997                     Zones configured for dynamic DNS may also use this
7998                     option to allow varying levels of automatic DNSSEC key
7999                     management. There are three possible settings:
8000                   </p>
8001 <p>
8002                     <span><strong class="command">auto-dnssec allow;</strong></span> permits
8003                     keys to be updated and the zone fully re-signed
8004                     whenever the user issues the command <span><strong class="command">rndc sign
8005                     <em class="replaceable"><code>zonename</code></em></strong></span>.
8006                   </p>
8007 <p>
8008                     <span><strong class="command">auto-dnssec maintain;</strong></span> includes the
8009                     above, but also automatically adjusts the zone's DNSSEC
8010                     keys on schedule, according to the keys' timing metadata
8011                     (see <a href="man.dnssec-keygen.html" title="dnssec-keygen"><span class="refentrytitle"><span class="application">dnssec-keygen</span></span>(8)</a> and
8012                     <a href="man.dnssec-settime.html" title="dnssec-settime"><span class="refentrytitle"><span class="application">dnssec-settime</span></span>(8)</a>).  The command
8013                     <span><strong class="command">rndc sign
8014                     <em class="replaceable"><code>zonename</code></em></strong></span> causes
8015                     <span><strong class="command">named</strong></span> to load keys from the key
8016                     repository and sign the zone with all keys that are
8017                     active. 
8018                     <span><strong class="command">rndc loadkeys
8019                     <em class="replaceable"><code>zonename</code></em></strong></span> causes
8020                     <span><strong class="command">named</strong></span> to load keys from the key
8021                     repository and schedule key maintenance events to occur
8022                     in the future, but it does not sign the full zone
8023                     immediately.  Note: once keys have been loaded for a
8024                     zone the first time, the repository will be searched
8025                     for changes periodically, regardless of whether
8026                     <span><strong class="command">rndc loadkeys</strong></span> is used.  The recheck
8027                     interval is defined by
8028                     <span><strong class="command">dnssec-loadkeys-interval</strong></span>.)
8029                   </p>
8030 <p>
8031                     The default setting is <span><strong class="command">auto-dnssec off</strong></span>.
8032                   </p>
8033 </dd>
8034 <dt><span class="term"><span><strong class="command">serial-update-method</strong></span></span></dt>
8035 <dd>
8036 <p>
8037                     Zones configured for dynamic DNS may use this
8038                     option to set the update method that will be used for
8039                     the zone serial number in the SOA record.
8040                   </p>
8041 <p>
8042                     With the default setting of
8043                     <span><strong class="command">serial-update-method increment;</strong></span>, the
8044                     SOA serial number will be incremented by one each time
8045                     the zone is updated.
8046                   </p>
8047 <p>
8048                     When set to 
8049                     <span><strong class="command">serial-update-method unixtime;</strong></span>, the
8050                     SOA serial number will be set to the number of seconds
8051                     since the UNIX epoch, unless the serial number is
8052                     already greater than or equal to that value, in which
8053                     case it is simply incremented by one.
8054                   </p>
8055 </dd>
8056 <dt><span class="term"><span><strong class="command">inline-signing</strong></span></span></dt>
8057 <dd><p>
8058                     If <code class="literal">yes</code>, this enables
8059                     "bump in the wire" signing of a zone, where a
8060                     unsigned zone is transferred in or loaded from
8061                     disk and a signed version of the zone is served,
8062                     with possibly, a different serial number.  This
8063                     behaviour is disabled by default.
8064                   </p></dd>
8065 <dt><span class="term"><span><strong class="command">multi-master</strong></span></span></dt>
8066 <dd><p>
8067                     See the description of <span><strong class="command">multi-master</strong></span> in
8068                     <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
8069                   </p></dd>
8070 <dt><span class="term"><span><strong class="command">masterfile-format</strong></span></span></dt>
8071 <dd><p>
8072                     See the description of <span><strong class="command">masterfile-format</strong></span>
8073                     in <a href="Bv9ARM.ch06.html#tuning" title="Tuning">the section called &#8220;Tuning&#8221;</a>.
8074                   </p></dd>
8075 <dt><span class="term"><span><strong class="command">dnssec-secure-to-insecure</strong></span></span></dt>
8076 <dd><p>
8077                     See the description of
8078                     <span><strong class="command">dnssec-secure-to-insecure</strong></span> in <a href="Bv9ARM.ch06.html#boolean_options" title="Boolean Options">the section called &#8220;Boolean Options&#8221;</a>.
8079                   </p></dd>
8080 </dl></div>
8081 </div>
8082 <div class="sect3" lang="en">
8083 <div class="titlepage"><div><div><h4 class="title">
8084 <a name="dynamic_update_policies"></a>Dynamic Update Policies</h4></div></div></div>
8085 <p><acronym class="acronym">BIND</acronym> 9 supports two alternative
8086               methods of granting clients the right to perform
8087               dynamic updates to a zone, configured by the
8088               <span><strong class="command">allow-update</strong></span> and
8089               <span><strong class="command">update-policy</strong></span> option, respectively.
8090             </p>
8091 <p>
8092               The <span><strong class="command">allow-update</strong></span> clause works the
8093               same way as in previous versions of <acronym class="acronym">BIND</acronym>.
8094               It grants given clients the permission to update any
8095               record of any name in the zone.
8096             </p>
8097 <p>
8098               The <span><strong class="command">update-policy</strong></span> clause
8099               allows more fine-grained control over what updates are
8100               allowed.  A set of rules is specified, where each rule
8101               either grants or denies permissions for one or more
8102               names to be updated by one or more identities.  If
8103               the dynamic update request message is signed (that is,
8104               it includes either a TSIG or SIG(0) record), the
8105               identity of the signer can be determined.
8106             </p>
8107 <p>
8108               Rules are specified in the <span><strong class="command">update-policy</strong></span>
8109               zone option, and are only meaningful for master zones.
8110               When the <span><strong class="command">update-policy</strong></span> statement
8111               is present, it is a configuration error for the
8112               <span><strong class="command">allow-update</strong></span> statement to be
8113               present.  The <span><strong class="command">update-policy</strong></span> statement
8114               only examines the signer of a message; the source
8115               address is not relevant.
8116             </p>
8117 <p>
8118               There is a pre-defined <span><strong class="command">update-policy</strong></span>
8119               rule which can be switched on with the command
8120               <span><strong class="command">update-policy local;</strong></span>.
8121               Switching on this rule in a zone causes
8122               <span><strong class="command">named</strong></span> to generate a TSIG session
8123               key and place it in a file, and to allow that key
8124               to update the zone.  (By default, the file is
8125               <code class="filename">/var/run/named/session.key</code>, the key
8126               name is "local-ddns" and the key algorithm is HMAC-SHA256,
8127               but these values are configurable with the
8128               <span><strong class="command">session-keyfile</strong></span>,
8129               <span><strong class="command">session-keyname</strong></span> and
8130               <span><strong class="command">session-keyalg</strong></span> options, respectively).
8131             </p>
8132 <p>
8133               A client running on the local system, and with appropriate
8134               permissions, may read that file and use the key to sign update
8135               requests.  The zone's update policy will be set to allow that
8136               key to change any record within the zone.  Assuming the
8137               key name is "local-ddns", this policy is equivalent to:
8138             </p>
8139 <pre class="programlisting">update-policy { grant local-ddns zonesub any; };
8140             </pre>
8141 <p>
8142               The command <span><strong class="command">nsupdate -l</strong></span> sends update
8143               requests to localhost, and signs them using the session key.
8144             </p>
8145 <p>
8146               Other rule definitions look like this:
8147             </p>
8148 <pre class="programlisting">
8149 ( <span><strong class="command">grant</strong></span> | <span><strong class="command">deny</strong></span> ) <em class="replaceable"><code>identity</code></em> <em class="replaceable"><code>nametype</code></em> [<span class="optional"> <em class="replaceable"><code>name</code></em> </span>] [<span class="optional"> <em class="replaceable"><code>types</code></em> </span>]
8150 </pre>
8151 <p>
8152               Each rule grants or denies privileges.  Once a message has
8153               successfully matched a rule, the operation is immediately
8154               granted or denied and no further rules are examined.  A rule
8155               is matched when the signer matches the identity field, the
8156               name matches the name field in accordance with the nametype
8157               field, and the type matches the types specified in the type
8158               field.
8159             </p>
8160 <p>
8161               No signer is required for <em class="replaceable"><code>tcp-self</code></em>
8162               or <em class="replaceable"><code>6to4-self</code></em> however the standard
8163               reverse mapping / prefix conversion must match the identity
8164               field.
8165             </p>
8166 <p>
8167               The identity field specifies a name or a wildcard
8168               name.  Normally, this is the name of the TSIG or
8169               SIG(0) key used to sign the update request.  When a
8170               TKEY exchange has been used to create a shared secret,
8171               the identity of the shared secret is the same as the
8172               identity of the key used to authenticate the TKEY
8173               exchange.  TKEY is also the negotiation method used
8174               by GSS-TSIG, which establishes an identity that is
8175               the Kerberos principal of the client, such as
8176               <strong class="userinput"><code>"user@host.domain"</code></strong>.  When the
8177               <em class="replaceable"><code>identity</code></em> field specifies
8178               a wildcard name, it is subject to DNS wildcard
8179               expansion, so the rule will apply to multiple identities.
8180               The <em class="replaceable"><code>identity</code></em> field must
8181               contain a fully-qualified domain name.
8182             </p>
8183 <p>
8184               For nametypes <code class="varname">krb5-self</code>,
8185               <code class="varname">ms-self</code>, <code class="varname">krb5-subdomain</code>,
8186               and <code class="varname">ms-subdomain</code> the
8187               <em class="replaceable"><code>identity</code></em> field specifies
8188               the Windows or Kerberos realm of the machine belongs to.
8189             </p>
8190 <p>
8191               The <em class="replaceable"><code>nametype</code></em> field has 13
8192               values:
8193               <code class="varname">name</code>, <code class="varname">subdomain</code>,
8194               <code class="varname">wildcard</code>, <code class="varname">self</code>,
8195               <code class="varname">selfsub</code>, <code class="varname">selfwild</code>,
8196               <code class="varname">krb5-self</code>, <code class="varname">ms-self</code>,
8197               <code class="varname">krb5-subdomain</code>,
8198               <code class="varname">ms-subdomain</code>,
8199               <code class="varname">tcp-self</code>, <code class="varname">6to4-self</code>,
8200               <code class="varname">zonesub</code>, and <code class="varname">external</code>.
8201             </p>
8202 <div class="informaltable"><table border="1">
8203 <colgroup>
8204 <col>
8205 <col>
8206 </colgroup>
8207 <tbody>
8208 <tr>
8209 <td>
8210                       <p>
8211                         <code class="varname">name</code>
8212                       </p>
8213                     </td>
8214 <td>
8215                       <p>
8216                         Exact-match semantics.  This rule matches
8217                         when the name being updated is identical
8218                         to the contents of the
8219                         <em class="replaceable"><code>name</code></em> field.
8220                       </p>
8221                     </td>
8222 </tr>
8223 <tr>
8224 <td>
8225                       <p>
8226                         <code class="varname">subdomain</code>
8227                       </p>
8228                     </td>
8229 <td>
8230                       <p>
8231                         This rule matches when the name being updated
8232                         is a subdomain of, or identical to, the
8233                         contents of the <em class="replaceable"><code>name</code></em>
8234                         field.
8235                       </p>
8236                     </td>
8237 </tr>
8238 <tr>
8239 <td>
8240                       <p>
8241                         <code class="varname">zonesub</code>
8242                       </p>
8243                     </td>
8244 <td>
8245                       <p>
8246                         This rule is similar to subdomain, except that
8247                         it matches when the name being updated is a
8248                         subdomain of the zone in which the
8249                         <span><strong class="command">update-policy</strong></span> statement
8250                         appears.  This obviates the need to type the zone
8251                         name twice, and enables the use of a standard
8252                         <span><strong class="command">update-policy</strong></span> statement in
8253                         multiple zones without modification.
8254                       </p>
8255                       <p>
8256                         When this rule is used, the
8257                         <em class="replaceable"><code>name</code></em> field is omitted.
8258                       </p>
8259                     </td>
8260 </tr>
8261 <tr>
8262 <td>
8263                       <p>
8264                         <code class="varname">wildcard</code>
8265                       </p>
8266                     </td>
8267 <td>
8268                       <p>
8269                         The <em class="replaceable"><code>name</code></em> field
8270                         is subject to DNS wildcard expansion, and
8271                         this rule matches when the name being updated
8272                         name is a valid expansion of the wildcard.
8273                       </p>
8274                     </td>
8275 </tr>
8276 <tr>
8277 <td>
8278                       <p>
8279                         <code class="varname">self</code>
8280                       </p>
8281                     </td>
8282 <td>
8283                       <p>
8284                         This rule matches when the name being updated
8285                         matches the contents of the
8286                         <em class="replaceable"><code>identity</code></em> field.
8287                         The <em class="replaceable"><code>name</code></em> field
8288                         is ignored, but should be the same as the
8289                         <em class="replaceable"><code>identity</code></em> field.
8290                         The <code class="varname">self</code> nametype is
8291                         most useful when allowing using one key per
8292                         name to update, where the key has the same
8293                         name as the name to be updated.  The
8294                         <em class="replaceable"><code>identity</code></em> would
8295                         be specified as <code class="constant">*</code> (an asterisk) in
8296                         this case.
8297                       </p>
8298                     </td>
8299 </tr>
8300 <tr>
8301 <td>
8302                       <p>
8303                         <code class="varname">selfsub</code>
8304                       </p>
8305                     </td>
8306 <td>
8307                       <p>
8308                         This rule is similar to <code class="varname">self</code>
8309                         except that subdomains of <code class="varname">self</code>
8310                         can also be updated.
8311                       </p>
8312                     </td>
8313 </tr>
8314 <tr>
8315 <td>
8316                       <p>
8317                         <code class="varname">selfwild</code>
8318                       </p>
8319                     </td>
8320 <td>
8321                       <p>
8322                         This rule is similar to <code class="varname">self</code>
8323                         except that only subdomains of
8324                         <code class="varname">self</code> can be updated.
8325                       </p>
8326                     </td>
8327 </tr>
8328 <tr>
8329 <td>
8330                       <p>
8331                         <code class="varname">ms-self</code>
8332                       </p>
8333                     </td>
8334 <td>
8335                       <p>
8336                         This rule takes a Windows machine principal
8337                         (machine$@REALM) for machine in REALM and
8338                         and converts it machine.realm allowing the machine 
8339                         to update machine.realm.  The REALM to be matched
8340                         is specified in the <em class="replaceable"><code>identity</code></em>
8341                         field.
8342                       </p>
8343                     </td>
8344 </tr>
8345 <tr>
8346 <td>
8347                       <p>
8348                         <code class="varname">ms-subdomain</code>
8349                       </p>
8350                     </td>
8351 <td>
8352                       <p>
8353                         This rule takes a Windows machine principal 
8354                         (machine$@REALM) for machine in REALM and
8355                         converts it to machine.realm allowing the machine
8356                         to update subdomains of machine.realm.  The REALM
8357                         to be matched is specified in the
8358                         <em class="replaceable"><code>identity</code></em> field.
8359                       </p>
8360                     </td>
8361 </tr>
8362 <tr>
8363 <td>
8364                       <p>
8365                         <code class="varname">krb5-self</code>
8366                       </p>
8367                     </td>
8368 <td>
8369                       <p>
8370                         This rule takes a Kerberos machine principal
8371                         (host/machine@REALM) for machine in REALM and
8372                         and converts it machine.realm allowing the machine 
8373                         to update machine.realm.  The REALM to be matched
8374                         is specified in the <em class="replaceable"><code>identity</code></em>
8375                         field.
8376                       </p>
8377                     </td>
8378 </tr>
8379 <tr>
8380 <td>
8381                       <p>
8382                         <code class="varname">krb5-subdomain</code>
8383                       </p>
8384                     </td>
8385 <td>
8386                       <p>
8387                         This rule takes a Kerberos machine principal 
8388                         (host/machine@REALM) for machine in REALM and
8389                         converts it to machine.realm allowing the machine
8390                         to update subdomains of machine.realm.  The REALM
8391                         to be matched is specified in the
8392                         <em class="replaceable"><code>identity</code></em> field.
8393                       </p>
8394                     </td>
8395 </tr>
8396 <tr>
8397 <td>
8398                       <p>
8399                         <code class="varname">tcp-self</code>
8400                       </p>
8401                     </td>
8402 <td>
8403                       <p>
8404                         Allow updates that have been sent via TCP and
8405                         for which the standard mapping from the initiating
8406                         IP address into the IN-ADDR.ARPA and IP6.ARPA
8407                         namespaces match the name to be updated.
8408                       </p>
8409                       <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
8410 <h3 class="title">Note</h3>
8411                         It is theoretically possible to spoof these TCP
8412                         sessions.
8413                       </div>
8414                     </td>
8415 </tr>
8416 <tr>
8417 <td>
8418                       <p>
8419                         <code class="varname">6to4-self</code>
8420                       </p>
8421                     </td>
8422 <td>
8423                       <p>
8424                         Allow the 6to4 prefix to be update by any TCP
8425                         connection from the 6to4 network or from the
8426                         corresponding IPv4 address.  This is intended
8427                         to allow NS or DNAME RRsets to be added to the
8428                         reverse tree.
8429                       </p>
8430                       <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
8431 <h3 class="title">Note</h3>
8432                         It is theoretically possible to spoof these TCP
8433                         sessions.
8434                       </div>
8435                     </td>
8436 </tr>
8437 <tr>
8438 <td>
8439                       <p>
8440                         <code class="varname">external</code>
8441                       </p>
8442                     </td>
8443 <td>
8444                       <p>
8445                         This rule allows <span><strong class="command">named</strong></span>
8446                         to defer the decision of whether to allow a
8447                         given update to an external daemon.
8448                       </p>
8449                       <p>
8450                         The method of communicating with the daemon is
8451                         specified in the <em class="replaceable"><code>identity</code></em>
8452                         field, the format of which is
8453                         "<code class="constant">local:</code><em class="replaceable"><code>path</code></em>",
8454                         where <em class="replaceable"><code>path</code></em> is the location
8455                         of a UNIX-domain socket.  (Currently, "local" is the
8456                         only supported mechanism.)
8457                       </p>
8458                       <p>
8459                         Requests to the external daemon are sent over the
8460                         UNIX-domain socket as datagrams with the following
8461                         format:
8462                       </p>
8463                       <pre class="programlisting">
8464    Protocol version number (4 bytes, network byte order, currently 1)
8465    Request length (4 bytes, network byte order)
8466    Signer (null-terminated string)
8467    Name (null-terminated string)
8468    TCP source address (null-terminated string)
8469    Rdata type (null-terminated string)
8470    Key (null-terminated string)
8471    TKEY token length (4 bytes, network byte order)
8472    TKEY token (remainder of packet)</pre>
8473                       <p>
8474                         The daemon replies with a four-byte value in
8475                         network byte order, containing either 0 or 1; 0
8476                         indicates that the specified update is not
8477                         permitted, and 1 indicates that it is.
8478                       </p>
8479                     </td>
8480 </tr>
8481 </tbody>
8482 </table></div>
8483 <p>
8484               In all cases, the <em class="replaceable"><code>name</code></em>
8485               field must specify a fully-qualified domain name.
8486             </p>
8487 <p>
8488               If no types are explicitly specified, this rule matches
8489               all types except RRSIG, NS, SOA, NSEC and NSEC3. Types
8490               may be specified by name, including "ANY" (ANY matches
8491               all types except NSEC and NSEC3, which can never be
8492               updated).  Note that when an attempt is made to delete
8493               all records associated with a name, the rules are
8494               checked for each existing record type.
8495             </p>
8496 </div>
8497 </div>
8498 </div>
8499 <div class="sect1" lang="en">
8500 <div class="titlepage"><div><div><h2 class="title" style="clear: both">
8501 <a name="id2596605"></a>Zone File</h2></div></div></div>
8502 <div class="sect2" lang="en">
8503 <div class="titlepage"><div><div><h3 class="title">
8504 <a name="types_of_resource_records_and_when_to_use_them"></a>Types of Resource Records and When to Use Them</h3></div></div></div>
8505 <p>
8506             This section, largely borrowed from RFC 1034, describes the
8507             concept of a Resource Record (RR) and explains when each is used.
8508             Since the publication of RFC 1034, several new RRs have been
8509             identified
8510             and implemented in the DNS. These are also included.
8511           </p>
8512 <div class="sect3" lang="en">
8513 <div class="titlepage"><div><div><h4 class="title">
8514 <a name="id2596624"></a>Resource Records</h4></div></div></div>
8515 <p>
8516               A domain name identifies a node.  Each node has a set of
8517               resource information, which may be empty.  The set of resource
8518               information associated with a particular name is composed of
8519               separate RRs. The order of RRs in a set is not significant and
8520               need not be preserved by name servers, resolvers, or other
8521               parts of the DNS. However, sorting of multiple RRs is
8522               permitted for optimization purposes, for example, to specify
8523               that a particular nearby server be tried first. See <a href="Bv9ARM.ch06.html#the_sortlist_statement" title="The sortlist Statement">the section called &#8220;The <span><strong class="command">sortlist</strong></span> Statement&#8221;</a> and <a href="Bv9ARM.ch06.html#rrset_ordering" title="RRset Ordering">the section called &#8220;RRset Ordering&#8221;</a>.
8524             </p>
8525 <p>
8526               The components of a Resource Record are:
8527             </p>
8528 <div class="informaltable"><table border="1">
8529 <colgroup>
8530 <col>
8531 <col>
8532 </colgroup>
8533 <tbody>
8534 <tr>
8535 <td>
8536                       <p>
8537                         owner name
8538                       </p>
8539                     </td>
8540 <td>
8541                       <p>
8542                         The domain name where the RR is found.
8543                       </p>
8544                     </td>
8545 </tr>
8546 <tr>
8547 <td>
8548                       <p>
8549                         type
8550                       </p>
8551                     </td>
8552 <td>
8553                       <p>
8554                         An encoded 16-bit value that specifies
8555                         the type of the resource record.
8556                       </p>
8557                     </td>
8558 </tr>
8559 <tr>
8560 <td>
8561                       <p>
8562                         TTL
8563                       </p>
8564                     </td>
8565 <td>
8566                       <p>
8567                         The time-to-live of the RR. This field
8568                         is a 32-bit integer in units of seconds, and is
8569                         primarily used by
8570                         resolvers when they cache RRs. The TTL describes how
8571                         long a RR can
8572                         be cached before it should be discarded.
8573                       </p>
8574                     </td>
8575 </tr>
8576 <tr>
8577 <td>
8578                       <p>
8579                         class
8580                       </p>
8581                     </td>
8582 <td>
8583                       <p>
8584                         An encoded 16-bit value that identifies
8585                         a protocol family or instance of a protocol.
8586                       </p>
8587                     </td>
8588 </tr>
8589 <tr>
8590 <td>
8591                       <p>
8592                         RDATA
8593                       </p>
8594                     </td>
8595 <td>
8596                       <p>
8597                         The resource data.  The format of the
8598                         data is type (and sometimes class) specific.
8599                       </p>
8600                     </td>
8601 </tr>
8602 </tbody>
8603 </table></div>
8604 <p>
8605               The following are <span class="emphasis"><em>types</em></span> of valid RRs:
8606             </p>
8607 <div class="informaltable"><table border="1">
8608 <colgroup>
8609 <col>
8610 <col>
8611 </colgroup>
8612 <tbody>
8613 <tr>
8614 <td>
8615                       <p>
8616                         A
8617                       </p>
8618                     </td>
8619 <td>
8620                       <p>
8621                         A host address.  In the IN class, this is a
8622                         32-bit IP address.  Described in RFC 1035.
8623                       </p>
8624                     </td>
8625 </tr>
8626 <tr>
8627 <td>
8628                       <p>
8629                         AAAA
8630                       </p>
8631                     </td>
8632 <td>
8633                       <p>
8634                         IPv6 address.  Described in RFC 1886.
8635                       </p>
8636                     </td>
8637 </tr>
8638 <tr>
8639 <td>
8640                       <p>
8641                         A6
8642                       </p>
8643                     </td>
8644 <td>
8645                       <p>
8646                         IPv6 address.  This can be a partial
8647                         address (a suffix) and an indirection to the name
8648                         where the rest of the
8649                         address (the prefix) can be found.  Experimental.
8650                         Described in RFC 2874.
8651                       </p>
8652                     </td>
8653 </tr>
8654 <tr>
8655 <td>
8656                       <p>
8657                         AFSDB
8658                       </p>
8659                     </td>
8660 <td>
8661                       <p>
8662                         Location of AFS database servers.
8663                         Experimental.  Described in RFC 1183.
8664                       </p>
8665                     </td>
8666 </tr>
8667 <tr>
8668 <td>
8669                       <p>
8670                         APL
8671                       </p>
8672                     </td>
8673 <td>
8674                       <p>
8675                         Address prefix list.  Experimental.
8676                         Described in RFC 3123.
8677                       </p>
8678                     </td>
8679 </tr>
8680 <tr>
8681 <td>
8682                       <p>
8683                         CERT
8684                       </p>
8685                     </td>
8686 <td>
8687                       <p>
8688                         Holds a digital certificate.
8689                         Described in RFC 2538.
8690                       </p>
8691                     </td>
8692 </tr>
8693 <tr>
8694 <td>
8695                       <p>
8696                         CNAME
8697                       </p>
8698                     </td>
8699 <td>
8700                       <p>
8701                         Identifies the canonical name of an alias.
8702                         Described in RFC 1035.
8703                       </p>
8704                     </td>
8705 </tr>
8706 <tr>
8707 <td>
8708                       <p>
8709                         DHCID
8710                       </p>
8711                     </td>
8712 <td>
8713                       <p>
8714                         Is used for identifying which DHCP client is
8715                         associated with this name.  Described in RFC 4701.
8716                       </p>
8717                     </td>
8718 </tr>
8719 <tr>
8720 <td>
8721                       <p>
8722                         DNAME
8723                       </p>
8724                     </td>
8725 <td>
8726                       <p>
8727                         Replaces the domain name specified with
8728                         another name to be looked up, effectively aliasing an
8729                         entire
8730                         subtree of the domain name space rather than a single
8731                         record
8732                         as in the case of the CNAME RR.
8733                         Described in RFC 2672.
8734                       </p>
8735                     </td>
8736 </tr>
8737 <tr>
8738 <td>
8739                       <p>
8740                         DNSKEY
8741                       </p>
8742                     </td>
8743 <td>
8744                       <p>
8745                         Stores a public key associated with a signed
8746                         DNS zone.  Described in RFC 4034.
8747                       </p>
8748                     </td>
8749 </tr>
8750 <tr>
8751 <td>
8752                       <p>
8753                         DS
8754                       </p>
8755                     </td>
8756 <td>
8757                       <p>
8758                         Stores the hash of a public key associated with a
8759                         signed DNS zone.  Described in RFC 4034.
8760                       </p>
8761                     </td>
8762 </tr>
8763 <tr>
8764 <td>
8765                       <p>
8766                         GPOS
8767                       </p>
8768                     </td>
8769 <td>
8770                       <p>
8771                         Specifies the global position.  Superseded by LOC.
8772                       </p>
8773                     </td>
8774 </tr>
8775 <tr>
8776 <td>
8777                       <p>
8778                         HINFO
8779                       </p>
8780                     </td>
8781 <td>
8782                       <p>
8783                         Identifies the CPU and OS used by a host.
8784                         Described in RFC 1035.
8785                       </p>
8786                     </td>
8787 </tr>
8788 <tr>
8789 <td>
8790                       <p>
8791                         IPSECKEY
8792                       </p>
8793                     </td>
8794 <td>
8795                       <p>
8796                         Provides a method for storing IPsec keying material in
8797                         DNS.  Described in RFC 4025.
8798                       </p>
8799                     </td>
8800 </tr>
8801 <tr>
8802 <td>
8803                       <p>
8804                         ISDN
8805                       </p>
8806                     </td>
8807 <td>
8808                       <p>
8809                         Representation of ISDN addresses.
8810                         Experimental.  Described in RFC 1183.
8811                       </p>
8812                     </td>
8813 </tr>
8814 <tr>
8815 <td>
8816                       <p>
8817                         KEY
8818                       </p>
8819                     </td>
8820 <td>
8821                       <p>
8822                         Stores a public key associated with a
8823                         DNS name.  Used in original DNSSEC; replaced
8824                         by DNSKEY in DNSSECbis, but still used with
8825                         SIG(0).  Described in RFCs 2535 and 2931.
8826                       </p>
8827                     </td>
8828 </tr>
8829 <tr>
8830 <td>
8831                       <p>
8832                         KX
8833                       </p>
8834                     </td>
8835 <td>
8836                       <p>
8837                         Identifies a key exchanger for this
8838                         DNS name.  Described in RFC 2230.
8839                       </p>
8840                     </td>
8841 </tr>
8842 <tr>
8843 <td>
8844                       <p>
8845                         LOC
8846                       </p>
8847                     </td>
8848 <td>
8849                       <p>
8850                         For storing GPS info.  Described in RFC 1876.
8851                         Experimental.
8852                       </p>
8853                     </td>
8854 </tr>
8855 <tr>
8856 <td>
8857                       <p>
8858                         MX
8859                       </p>
8860                     </td>
8861 <td>
8862                       <p>
8863                         Identifies a mail exchange for the domain with
8864                         a 16-bit preference value (lower is better)
8865                         followed by the host name of the mail exchange.
8866                         Described in RFC 974, RFC 1035.
8867                       </p>
8868                     </td>
8869 </tr>
8870 <tr>
8871 <td>
8872                       <p>
8873                         NAPTR
8874                       </p>
8875                     </td>
8876 <td>
8877                       <p>
8878                         Name authority pointer.  Described in RFC 2915.
8879                       </p>
8880                     </td>
8881 </tr>
8882 <tr>
8883 <td>
8884                       <p>
8885                         NSAP
8886                       </p>
8887                     </td>
8888 <td>
8889                       <p>
8890                         A network service access point.
8891                         Described in RFC 1706.
8892                       </p>
8893                     </td>
8894 </tr>
8895 <tr>
8896 <td>
8897                       <p>
8898                         NS
8899                       </p>
8900                     </td>
8901 <td>
8902                       <p>
8903                         The authoritative name server for the
8904                         domain.  Described in RFC 1035.
8905                       </p>
8906                     </td>
8907 </tr>
8908 <tr>
8909 <td>
8910                       <p>
8911                         NSEC
8912                       </p>
8913                     </td>
8914 <td>
8915                       <p>
8916                         Used in DNSSECbis to securely indicate that
8917                         RRs with an owner name in a certain name interval do
8918                         not exist in
8919                         a zone and indicate what RR types are present for an
8920                         existing name.
8921                         Described in RFC 4034.
8922                       </p>
8923                     </td>
8924 </tr>
8925 <tr>
8926 <td>
8927                       <p>
8928                         NSEC3
8929                       </p>
8930                     </td>
8931 <td>
8932                       <p>
8933                         Used in DNSSECbis to securely indicate that
8934                         RRs with an owner name in a certain name
8935                         interval do not exist in a zone and indicate
8936                         what RR types are present for an existing
8937                         name.  NSEC3 differs from NSEC in that it
8938                         prevents zone enumeration but is more
8939                         computationally expensive on both the server
8940                         and the client than NSEC.  Described in RFC
8941                         5155.
8942                       </p>
8943                     </td>
8944 </tr>
8945 <tr>
8946 <td>
8947                       <p>
8948                         NSEC3PARAM
8949                       </p>
8950                     </td>
8951 <td>
8952                       <p>
8953                         Used in DNSSECbis to tell the authoritative
8954                         server which NSEC3 chains are available to use.
8955                         Described in RFC 5155.
8956                       </p>
8957                     </td>
8958 </tr>
8959 <tr>
8960 <td>
8961                       <p>
8962                         NXT
8963                       </p>
8964                     </td>
8965 <td>
8966                       <p>
8967                         Used in DNSSEC to securely indicate that
8968                         RRs with an owner name in a certain name interval do
8969                         not exist in
8970                         a zone and indicate what RR types are present for an
8971                         existing name.
8972                         Used in original DNSSEC; replaced by NSEC in
8973                         DNSSECbis.
8974                         Described in RFC 2535.
8975                       </p>
8976                     </td>
8977 </tr>
8978 <tr>
8979 <td>
8980                       <p>
8981                         PTR
8982                       </p>
8983                     </td>
8984 <td>
8985                       <p>
8986                         A pointer to another part of the domain
8987                         name space.  Described in RFC 1035.
8988                       </p>
8989                     </td>
8990 </tr>
8991 <tr>
8992 <td>
8993                       <p>
8994                         PX
8995                       </p>
8996                     </td>
8997 <td>
8998                       <p>
8999                         Provides mappings between RFC 822 and X.400
9000                         addresses.  Described in RFC 2163.
9001                       </p>
9002                     </td>
9003 </tr>
9004 <tr>
9005 <td>
9006                       <p>
9007                         RP
9008                       </p>
9009                     </td>
9010 <td>
9011                       <p>
9012                         Information on persons responsible
9013                         for the domain.  Experimental.  Described in RFC 1183.
9014                       </p>
9015                     </td>
9016 </tr>
9017 <tr>
9018 <td>
9019                       <p>
9020                         RRSIG
9021                       </p>
9022                     </td>
9023 <td>
9024                       <p>
9025                         Contains DNSSECbis signature data.  Described
9026                         in RFC 4034.
9027                       </p>
9028                     </td>
9029 </tr>
9030 <tr>
9031 <td>
9032                       <p>
9033                         RT
9034                       </p>
9035                     </td>
9036 <td>
9037                       <p>
9038                         Route-through binding for hosts that
9039                         do not have their own direct wide area network
9040                         addresses.
9041                         Experimental.  Described in RFC 1183.
9042                       </p>
9043                     </td>
9044 </tr>
9045 <tr>
9046 <td>
9047                       <p>
9048                         SIG
9049                       </p>
9050                     </td>
9051 <td>
9052                       <p>
9053                         Contains DNSSEC signature data.  Used in
9054                         original DNSSEC; replaced by RRSIG in
9055                         DNSSECbis, but still used for SIG(0).
9056                         Described in RFCs 2535 and 2931.
9057                       </p>
9058                     </td>
9059 </tr>
9060 <tr>
9061 <td>
9062                       <p>
9063                         SOA
9064                       </p>
9065                     </td>
9066 <td>
9067                       <p>
9068                         Identifies the start of a zone of authority.
9069                         Described in RFC 1035.
9070                       </p>
9071                     </td>
9072 </tr>
9073 <tr>
9074 <td>
9075                       <p>
9076                         SPF
9077                       </p>
9078                     </td>
9079 <td>
9080                       <p>
9081                         Contains the Sender Policy Framework information
9082                         for a given email domain.  Described in RFC 4408.
9083                       </p>
9084                     </td>
9085 </tr>
9086 <tr>
9087 <td>
9088                       <p>
9089                         SRV
9090                       </p>
9091                     </td>
9092 <td>
9093                       <p>
9094                         Information about well known network
9095                         services (replaces WKS).  Described in RFC 2782.
9096                       </p>
9097                     </td>
9098 </tr>
9099 <tr>
9100 <td>
9101                       <p>
9102                         SSHFP
9103                       </p>
9104                     </td>
9105 <td>
9106                       <p>
9107                         Provides a way to securely publish a secure shell key's
9108                         fingerprint.  Described in RFC 4255.
9109                       </p>
9110                     </td>
9111 </tr>
9112 <tr>
9113 <td>
9114                       <p>
9115                         TXT
9116                       </p>
9117                     </td>
9118 <td>
9119                       <p>
9120                         Text records.  Described in RFC 1035.
9121                       </p>
9122                     </td>
9123 </tr>
9124 <tr>
9125 <td>
9126                       <p>
9127                         WKS
9128                       </p>
9129                     </td>
9130 <td>
9131                       <p>
9132                         Information about which well known
9133                         network services, such as SMTP, that a domain
9134                         supports. Historical.
9135                       </p>
9136                     </td>
9137 </tr>
9138 <tr>
9139 <td>
9140                       <p>
9141                         X25
9142                       </p>
9143                     </td>
9144 <td>
9145                       <p>
9146                         Representation of X.25 network addresses.
9147                         Experimental.  Described in RFC 1183.
9148                       </p>
9149                     </td>
9150 </tr>
9151 </tbody>
9152 </table></div>
9153 <p>
9154               The following <span class="emphasis"><em>classes</em></span> of resource records
9155               are currently valid in the DNS:
9156             </p>
9157 <div class="informaltable"><table border="1">
9158 <colgroup>
9159 <col>
9160 <col>
9161 </colgroup>
9162 <tbody>
9163 <tr>
9164 <td>
9165                       <p>
9166                         IN
9167                       </p>
9168                     </td>
9169 <td>
9170                       <p>
9171                         The Internet.
9172                       </p>
9173                     </td>
9174 </tr>
9175 <tr>
9176 <td>
9177                       <p>
9178                         CH
9179                       </p>
9180                     </td>
9181 <td>
9182                       <p>
9183                         Chaosnet, a LAN protocol created at MIT in the
9184                         mid-1970s.
9185                         Rarely used for its historical purpose, but reused for
9186                         BIND's
9187                         built-in server information zones, e.g.,
9188                         <code class="literal">version.bind</code>.
9189                       </p>
9190                     </td>
9191 </tr>
9192 <tr>
9193 <td>
9194                       <p>
9195                         HS
9196                       </p>
9197                     </td>
9198 <td>
9199                       <p>
9200                         Hesiod, an information service
9201                         developed by MIT's Project Athena. It is used to share
9202                         information
9203                         about various systems databases, such as users,
9204                         groups, printers
9205                         and so on.
9206                       </p>
9207                     </td>
9208 </tr>
9209 </tbody>
9210 </table></div>
9211 <p>
9212               The owner name is often implicit, rather than forming an
9213               integral
9214               part of the RR.  For example, many name servers internally form
9215               tree
9216               or hash structures for the name space, and chain RRs off nodes.
9217               The remaining RR parts are the fixed header (type, class, TTL)
9218               which is consistent for all RRs, and a variable part (RDATA)
9219               that
9220               fits the needs of the resource being described.
9221             </p>
9222 <p>
9223               The meaning of the TTL field is a time limit on how long an
9224               RR can be kept in a cache.  This limit does not apply to
9225               authoritative
9226               data in zones; it is also timed out, but by the refreshing
9227               policies
9228               for the zone.  The TTL is assigned by the administrator for the
9229               zone where the data originates.  While short TTLs can be used to
9230               minimize caching, and a zero TTL prohibits caching, the
9231               realities
9232               of Internet performance suggest that these times should be on
9233               the
9234               order of days for the typical host.  If a change can be
9235               anticipated,
9236               the TTL can be reduced prior to the change to minimize
9237               inconsistency
9238               during the change, and then increased back to its former value
9239               following
9240               the change.
9241             </p>
9242 <p>
9243               The data in the RDATA section of RRs is carried as a combination
9244               of binary strings and domain names.  The domain names are
9245               frequently
9246               used as "pointers" to other data in the DNS.
9247             </p>
9248 </div>
9249 <div class="sect3" lang="en">
9250 <div class="titlepage"><div><div><h4 class="title">
9251 <a name="id2598247"></a>Textual expression of RRs</h4></div></div></div>
9252 <p>
9253               RRs are represented in binary form in the packets of the DNS
9254               protocol, and are usually represented in highly encoded form
9255               when
9256               stored in a name server or resolver.  In the examples provided
9257               in
9258               RFC 1034, a style similar to that used in master files was
9259               employed
9260               in order to show the contents of RRs.  In this format, most RRs
9261               are shown on a single line, although continuation lines are
9262               possible
9263               using parentheses.
9264             </p>
9265 <p>
9266               The start of the line gives the owner of the RR.  If a line
9267               begins with a blank, then the owner is assumed to be the same as
9268               that of the previous RR.  Blank lines are often included for
9269               readability.
9270             </p>
9271 <p>
9272               Following the owner, we list the TTL, type, and class of the
9273               RR.  Class and type use the mnemonics defined above, and TTL is
9274               an integer before the type field.  In order to avoid ambiguity
9275               in
9276               parsing, type and class mnemonics are disjoint, TTLs are
9277               integers,
9278               and the type mnemonic is always last. The IN class and TTL
9279               values
9280               are often omitted from examples in the interests of clarity.
9281             </p>
9282 <p>
9283               The resource data or RDATA section of the RR are given using
9284               knowledge of the typical representation for the data.
9285             </p>
9286 <p>
9287               For example, we might show the RRs carried in a message as:
9288             </p>
9289 <div class="informaltable"><table border="1">
9290 <colgroup>
9291 <col>
9292 <col>
9293 <col>
9294 </colgroup>
9295 <tbody>
9296 <tr>
9297 <td>
9298                       <p>
9299                         <code class="literal">ISI.EDU.</code>
9300                       </p>
9301                     </td>
9302 <td>
9303                       <p>
9304                         <code class="literal">MX</code>
9305                       </p>
9306                     </td>
9307 <td>
9308                       <p>
9309                         <code class="literal">10 VENERA.ISI.EDU.</code>
9310                       </p>
9311                     </td>
9312 </tr>
9313 <tr>
9314 <td>
9315                       <p></p>
9316                     </td>
9317 <td>
9318                       <p>
9319                         <code class="literal">MX</code>
9320                       </p>
9321                     </td>
9322 <td>
9323                       <p>
9324                         <code class="literal">10 VAXA.ISI.EDU</code>
9325                       </p>
9326                     </td>
9327 </tr>
9328 <tr>
9329 <td>
9330                       <p>
9331                         <code class="literal">VENERA.ISI.EDU</code>
9332                       </p>
9333                     </td>
9334 <td>
9335                       <p>
9336                         <code class="literal">A</code>
9337                       </p>
9338                     </td>
9339 <td>
9340                       <p>
9341                         <code class="literal">128.9.0.32</code>
9342                       </p>
9343                     </td>
9344 </tr>
9345 <tr>
9346 <td>
9347                       <p></p>
9348                     </td>
9349 <td>
9350                       <p>
9351                         <code class="literal">A</code>
9352                       </p>
9353                     </td>
9354 <td>
9355                       <p>
9356                         <code class="literal">10.1.0.52</code>
9357                       </p>
9358                     </td>
9359 </tr>
9360 <tr>
9361 <td>
9362                       <p>
9363                         <code class="literal">VAXA.ISI.EDU</code>
9364                       </p>
9365                     </td>
9366 <td>
9367                       <p>
9368                         <code class="literal">A</code>
9369                       </p>
9370                     </td>
9371 <td>
9372                       <p>
9373                         <code class="literal">10.2.0.27</code>
9374                       </p>
9375                     </td>
9376 </tr>
9377 <tr>
9378 <td>
9379                       <p></p>
9380                     </td>
9381 <td>
9382                       <p>
9383                         <code class="literal">A</code>
9384                       </p>
9385                     </td>
9386 <td>
9387                       <p>
9388                         <code class="literal">128.9.0.33</code>
9389                       </p>
9390                     </td>
9391 </tr>
9392 </tbody>
9393 </table></div>
9394 <p>
9395               The MX RRs have an RDATA section which consists of a 16-bit
9396               number followed by a domain name.  The address RRs use a
9397               standard
9398               IP address format to contain a 32-bit internet address.
9399             </p>
9400 <p>
9401               The above example shows six RRs, with two RRs at each of three
9402               domain names.
9403             </p>
9404 <p>
9405               Similarly we might see:
9406             </p>
9407 <div class="informaltable"><table border="1">
9408 <colgroup>
9409 <col>
9410 <col>
9411 <col>
9412 </colgroup>
9413 <tbody>
9414 <tr>
9415 <td>
9416                       <p>
9417                         <code class="literal">XX.LCS.MIT.EDU.</code>
9418                       </p>
9419                     </td>
9420 <td>
9421                       <p>
9422                         <code class="literal">IN A</code>
9423                       </p>
9424                     </td>
9425 <td>
9426                       <p>
9427                         <code class="literal">10.0.0.44</code>
9428                       </p>
9429                     </td>
9430 </tr>
9431 <tr>
9432 <td> </td>
9433 <td>
9434                       <p>
9435                         <code class="literal">CH A</code>
9436                       </p>
9437                     </td>
9438 <td>
9439                       <p>
9440                         <code class="literal">MIT.EDU. 2420</code>
9441                       </p>
9442                     </td>
9443 </tr>
9444 </tbody>
9445 </table></div>
9446 <p>
9447               This example shows two addresses for
9448               <code class="literal">XX.LCS.MIT.EDU</code>, each of a different class.
9449             </p>
9450 </div>
9451 </div>
9452 <div class="sect2" lang="en">
9453 <div class="titlepage"><div><div><h3 class="title">
9454 <a name="id2598768"></a>Discussion of MX Records</h3></div></div></div>
9455 <p>
9456             As described above, domain servers store information as a
9457             series of resource records, each of which contains a particular
9458             piece of information about a given domain name (which is usually,
9459             but not always, a host). The simplest way to think of a RR is as
9460             a typed pair of data, a domain name matched with a relevant datum,
9461             and stored with some additional type information to help systems
9462             determine when the RR is relevant.
9463           </p>
9464 <p>
9465             MX records are used to control delivery of email. The data
9466             specified in the record is a priority and a domain name. The
9467             priority
9468             controls the order in which email delivery is attempted, with the
9469             lowest number first. If two priorities are the same, a server is
9470             chosen randomly. If no servers at a given priority are responding,
9471             the mail transport agent will fall back to the next largest
9472             priority.
9473             Priority numbers do not have any absolute meaning &#8212; they are
9474             relevant
9475             only respective to other MX records for that domain name. The
9476             domain
9477             name given is the machine to which the mail will be delivered.
9478             It <span class="emphasis"><em>must</em></span> have an associated address record
9479             (A or AAAA) &#8212; CNAME is not sufficient.
9480           </p>
9481 <p>
9482             For a given domain, if there is both a CNAME record and an
9483             MX record, the MX record is in error, and will be ignored.
9484             Instead,
9485             the mail will be delivered to the server specified in the MX
9486             record
9487             pointed to by the CNAME.
9488             For example:
9489           </p>
9490 <div class="informaltable"><table border="1">
9491 <colgroup>
9492 <col>
9493 <col>
9494 <col>
9495 <col>
9496 <col>
9497 </colgroup>
9498 <tbody>
9499 <tr>
9500 <td>
9501                     <p>
9502                       <code class="literal">example.com.</code>
9503                     </p>
9504                   </td>
9505 <td>
9506                     <p>
9507                       <code class="literal">IN</code>
9508                     </p>
9509                   </td>
9510 <td>
9511                     <p>
9512                       <code class="literal">MX</code>
9513                     </p>
9514                   </td>
9515 <td>
9516                     <p>
9517                       <code class="literal">10</code>
9518                     </p>
9519                   </td>
9520 <td>
9521                     <p>
9522                       <code class="literal">mail.example.com.</code>
9523                     </p>
9524                   </td>
9525 </tr>
9526 <tr>
9527 <td>
9528                     <p></p>
9529                   </td>
9530 <td>
9531                     <p>
9532                       <code class="literal">IN</code>
9533                     </p>
9534                   </td>
9535 <td>
9536                     <p>
9537                       <code class="literal">MX</code>
9538                     </p>
9539                   </td>
9540 <td>
9541                     <p>
9542                       <code class="literal">10</code>
9543                     </p>
9544                   </td>
9545 <td>
9546                     <p>
9547                       <code class="literal">mail2.example.com.</code>
9548                     </p>
9549                   </td>
9550 </tr>
9551 <tr>
9552 <td>
9553                     <p></p>
9554                   </td>
9555 <td>
9556                     <p>
9557                       <code class="literal">IN</code>
9558                     </p>
9559                   </td>
9560 <td>
9561                     <p>
9562                       <code class="literal">MX</code>
9563                     </p>
9564                   </td>
9565 <td>
9566                     <p>
9567                       <code class="literal">20</code>
9568                     </p>
9569                   </td>
9570 <td>
9571                     <p>
9572                       <code class="literal">mail.backup.org.</code>
9573                     </p>
9574                   </td>
9575 </tr>
9576 <tr>
9577 <td>
9578                     <p>
9579                       <code class="literal">mail.example.com.</code>
9580                     </p>
9581                   </td>
9582 <td>
9583                     <p>
9584                       <code class="literal">IN</code>
9585                     </p>
9586                   </td>
9587 <td>
9588                     <p>
9589                       <code class="literal">A</code>
9590                     </p>
9591                   </td>
9592 <td>
9593                     <p>
9594                       <code class="literal">10.0.0.1</code>
9595                     </p>
9596                   </td>
9597 <td>
9598                     <p></p>
9599                   </td>
9600 </tr>
9601 <tr>
9602 <td>
9603                     <p>
9604                       <code class="literal">mail2.example.com.</code>
9605                     </p>
9606                   </td>
9607 <td>
9608                     <p>
9609                       <code class="literal">IN</code>
9610                     </p>
9611                   </td>
9612 <td>
9613                     <p>
9614                       <code class="literal">A</code>
9615                     </p>
9616                   </td>
9617 <td>
9618                     <p>
9619                       <code class="literal">10.0.0.2</code>
9620                     </p>
9621                   </td>
9622 <td>
9623                     <p></p>
9624                   </td>
9625 </tr>
9626 </tbody>
9627 </table></div>
9628 <p>
9629             Mail delivery will be attempted to <code class="literal">mail.example.com</code> and
9630             <code class="literal">mail2.example.com</code> (in
9631             any order), and if neither of those succeed, delivery to <code class="literal">mail.backup.org</code> will
9632             be attempted.
9633           </p>
9634 </div>
9635 <div class="sect2" lang="en">
9636 <div class="titlepage"><div><div><h3 class="title">
9637 <a name="Setting_TTLs"></a>Setting TTLs</h3></div></div></div>
9638 <p>
9639             The time-to-live of the RR field is a 32-bit integer represented
9640             in units of seconds, and is primarily used by resolvers when they
9641             cache RRs. The TTL describes how long a RR can be cached before it
9642             should be discarded. The following three types of TTL are
9643             currently
9644             used in a zone file.
9645           </p>
9646 <div class="informaltable"><table border="1">
9647 <colgroup>
9648 <col>
9649 <col>
9650 </colgroup>
9651 <tbody>
9652 <tr>
9653 <td>
9654                     <p>
9655                       SOA
9656                     </p>
9657                   </td>
9658 <td>
9659                     <p>
9660                       The last field in the SOA is the negative
9661                       caching TTL. This controls how long other servers will
9662                       cache no-such-domain
9663                       (NXDOMAIN) responses from you.
9664                     </p>
9665                     <p>
9666                       The maximum time for
9667                       negative caching is 3 hours (3h).
9668                     </p>
9669                   </td>
9670 </tr>
9671 <tr>
9672 <td>
9673                     <p>
9674                       $TTL
9675                     </p>
9676                   </td>
9677 <td>
9678                     <p>
9679                       The $TTL directive at the top of the
9680                       zone file (before the SOA) gives a default TTL for every
9681                       RR without
9682                       a specific TTL set.
9683                     </p>
9684                   </td>
9685 </tr>
9686 <tr>
9687 <td>
9688                     <p>
9689                       RR TTLs
9690                     </p>
9691                   </td>
9692 <td>
9693                     <p>
9694                       Each RR can have a TTL as the second
9695                       field in the RR, which will control how long other
9696                       servers can cache it.
9697                     </p>
9698                   </td>
9699 </tr>
9700 </tbody>
9701 </table></div>
9702 <p>
9703             All of these TTLs default to units of seconds, though units
9704             can be explicitly specified, for example, <code class="literal">1h30m</code>.
9705           </p>
9706 </div>
9707 <div class="sect2" lang="en">
9708 <div class="titlepage"><div><div><h3 class="title">
9709 <a name="id2599451"></a>Inverse Mapping in IPv4</h3></div></div></div>
9710 <p>
9711             Reverse name resolution (that is, translation from IP address
9712             to name) is achieved by means of the <span class="emphasis"><em>in-addr.arpa</em></span> domain
9713             and PTR records. Entries in the in-addr.arpa domain are made in
9714             least-to-most significant order, read left to right. This is the
9715             opposite order to the way IP addresses are usually written. Thus,
9716             a machine with an IP address of 10.1.2.3 would have a
9717             corresponding
9718             in-addr.arpa name of
9719             3.2.1.10.in-addr.arpa. This name should have a PTR resource record
9720             whose data field is the name of the machine or, optionally,
9721             multiple
9722             PTR records if the machine has more than one name. For example,
9723             in the [<span class="optional">example.com</span>] domain:
9724           </p>
9725 <div class="informaltable"><table border="1">
9726 <colgroup>
9727 <col>
9728 <col>
9729 </colgroup>
9730 <tbody>
9731 <tr>
9732 <td>
9733                     <p>
9734                       <code class="literal">$ORIGIN</code>
9735                     </p>
9736                   </td>
9737 <td>
9738                     <p>
9739                       <code class="literal">2.1.10.in-addr.arpa</code>
9740                     </p>
9741                   </td>
9742 </tr>
9743 <tr>
9744 <td>
9745                     <p>
9746                       <code class="literal">3</code>
9747                     </p>
9748                   </td>
9749 <td>
9750                     <p>
9751                       <code class="literal">IN PTR foo.example.com.</code>
9752                     </p>
9753                   </td>
9754 </tr>
9755 </tbody>
9756 </table></div>
9757 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
9758 <h3 class="title">Note</h3>
9759 <p>
9760               The <span><strong class="command">$ORIGIN</strong></span> lines in the examples
9761               are for providing context to the examples only &#8212; they do not
9762               necessarily
9763               appear in the actual usage. They are only used here to indicate
9764               that the example is relative to the listed origin.
9765             </p>
9766 </div>
9767 </div>
9768 <div class="sect2" lang="en">
9769 <div class="titlepage"><div><div><h3 class="title">
9770 <a name="id2599578"></a>Other Zone File Directives</h3></div></div></div>
9771 <p>
9772             The Master File Format was initially defined in RFC 1035 and
9773             has subsequently been extended. While the Master File Format
9774             itself
9775             is class independent all records in a Master File must be of the
9776             same
9777             class.
9778           </p>
9779 <p>
9780             Master File Directives include <span><strong class="command">$ORIGIN</strong></span>, <span><strong class="command">$INCLUDE</strong></span>,
9781             and <span><strong class="command">$TTL.</strong></span>
9782           </p>
9783 <div class="sect3" lang="en">
9784 <div class="titlepage"><div><div><h4 class="title">
9785 <a name="id2599601"></a>The <span><strong class="command">@</strong></span> (at-sign)</h4></div></div></div>
9786 <p>
9787               When used in the label (or name) field, the asperand or
9788               at-sign (@) symbol represents the current origin.
9789               At the start of the zone file, it is the 
9790               &lt;<code class="varname">zone_name</code>&gt; (followed by
9791               trailing dot).
9792             </p>
9793 </div>
9794 <div class="sect3" lang="en">
9795 <div class="titlepage"><div><div><h4 class="title">
9796 <a name="id2599617"></a>The <span><strong class="command">$ORIGIN</strong></span> Directive</h4></div></div></div>
9797 <p>
9798               Syntax: <span><strong class="command">$ORIGIN</strong></span>
9799               <em class="replaceable"><code>domain-name</code></em>
9800               [<span class="optional"><em class="replaceable"><code>comment</code></em></span>]
9801             </p>
9802 <p><span><strong class="command">$ORIGIN</strong></span>
9803               sets the domain name that will be appended to any
9804               unqualified records. When a zone is first read in there
9805               is an implicit <span><strong class="command">$ORIGIN</strong></span>
9806               &lt;<code class="varname">zone_name</code>&gt;<span><strong class="command">.</strong></span>
9807               (followed by trailing dot).
9808               The current <span><strong class="command">$ORIGIN</strong></span> is appended to
9809               the domain specified in the <span><strong class="command">$ORIGIN</strong></span>
9810               argument if it is not absolute.
9811             </p>
9812 <pre class="programlisting">
9813 $ORIGIN example.com.
9814 WWW     CNAME   MAIN-SERVER
9815 </pre>
9816 <p>
9817               is equivalent to
9818             </p>
9819 <pre class="programlisting">
9820 WWW.EXAMPLE.COM. CNAME MAIN-SERVER.EXAMPLE.COM.
9821 </pre>
9822 </div>
9823 <div class="sect3" lang="en">
9824 <div class="titlepage"><div><div><h4 class="title">
9825 <a name="id2599746"></a>The <span><strong class="command">$INCLUDE</strong></span> Directive</h4></div></div></div>
9826 <p>
9827               Syntax: <span><strong class="command">$INCLUDE</strong></span>
9828               <em class="replaceable"><code>filename</code></em>
9829               [<span class="optional">
9830 <em class="replaceable"><code>origin</code></em> </span>]
9831               [<span class="optional"> <em class="replaceable"><code>comment</code></em> </span>]
9832             </p>
9833 <p>
9834               Read and process the file <code class="filename">filename</code> as
9835               if it were included into the file at this point.  If <span><strong class="command">origin</strong></span> is
9836               specified the file is processed with <span><strong class="command">$ORIGIN</strong></span> set
9837               to that value, otherwise the current <span><strong class="command">$ORIGIN</strong></span> is
9838               used.
9839             </p>
9840 <p>
9841               The origin and the current domain name
9842               revert to the values they had prior to the <span><strong class="command">$INCLUDE</strong></span> once
9843               the file has been read.
9844             </p>
9845 <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
9846 <h3 class="title">Note</h3>
9847 <p>
9848                 RFC 1035 specifies that the current origin should be restored
9849                 after
9850                 an <span><strong class="command">$INCLUDE</strong></span>, but it is silent
9851                 on whether the current
9852                 domain name should also be restored.  BIND 9 restores both of
9853                 them.
9854                 This could be construed as a deviation from RFC 1035, a
9855                 feature, or both.
9856               </p>
9857 </div>
9858 </div>
9859 <div class="sect3" lang="en">
9860 <div class="titlepage"><div><div><h4 class="title">
9861 <a name="id2599815"></a>The <span><strong class="command">$TTL</strong></span> Directive</h4></div></div></div>
9862 <p>
9863               Syntax: <span><strong class="command">$TTL</strong></span>
9864               <em class="replaceable"><code>default-ttl</code></em>
9865               [<span class="optional">
9866 <em class="replaceable"><code>comment</code></em> </span>]
9867             </p>
9868 <p>
9869               Set the default Time To Live (TTL) for subsequent records
9870               with undefined TTLs. Valid TTLs are of the range 0-2147483647
9871               seconds.
9872             </p>
9873 <p><span><strong class="command">$TTL</strong></span>
9874                is defined in RFC 2308.
9875             </p>
9876 </div>
9877 </div>
9878 <div class="sect2" lang="en">
9879 <div class="titlepage"><div><div><h3 class="title">
9880 <a name="id2599851"></a><acronym class="acronym">BIND</acronym> Master File Extension: the  <span><strong class="command">$GENERATE</strong></span> Directive</h3></div></div></div>
9881 <p>
9882             Syntax: <span><strong class="command">$GENERATE</strong></span>
9883             <em class="replaceable"><code>range</code></em>
9884             <em class="replaceable"><code>lhs</code></em>
9885             [<span class="optional"><em class="replaceable"><code>ttl</code></em></span>]
9886             [<span class="optional"><em class="replaceable"><code>class</code></em></span>]
9887             <em class="replaceable"><code>type</code></em>
9888             <em class="replaceable"><code>rhs</code></em>
9889             [<span class="optional"><em class="replaceable"><code>comment</code></em></span>]
9890           </p>
9891 <p><span><strong class="command">$GENERATE</strong></span>
9892             is used to create a series of resource records that only
9893             differ from each other by an
9894             iterator. <span><strong class="command">$GENERATE</strong></span> can be used to
9895             easily generate the sets of records required to support
9896             sub /24 reverse delegations described in RFC 2317:
9897             Classless IN-ADDR.ARPA delegation.
9898           </p>
9899 <pre class="programlisting">$ORIGIN 0.0.192.IN-ADDR.ARPA.
9900 $GENERATE 1-2 @ NS SERVER$.EXAMPLE.
9901 $GENERATE 1-127 $ CNAME $.0</pre>
9902 <p>
9903             is equivalent to
9904           </p>
9905 <pre class="programlisting">0.0.0.192.IN-ADDR.ARPA. NS SERVER1.EXAMPLE.
9906 0.0.0.192.IN-ADDR.ARPA. NS SERVER2.EXAMPLE.
9907 1.0.0.192.IN-ADDR.ARPA. CNAME 1.0.0.0.192.IN-ADDR.ARPA.
9908 2.0.0.192.IN-ADDR.ARPA. CNAME 2.0.0.0.192.IN-ADDR.ARPA.
9909 ...
9910 127.0.0.192.IN-ADDR.ARPA. CNAME 127.0.0.0.192.IN-ADDR.ARPA.
9911 </pre>
9912 <p>
9913             Generate a set of A and MX records.  Note the MX's right hand
9914             side is a quoted string.  The quotes will be stripped when the
9915             right hand side is processed.
9916            </p>
9917 <pre class="programlisting">
9918 $ORIGIN EXAMPLE.
9919 $GENERATE 1-127 HOST-$ A 1.2.3.$
9920 $GENERATE 1-127 HOST-$ MX "0 ."</pre>
9921 <p>
9922             is equivalent to
9923           </p>
9924 <pre class="programlisting">HOST-1.EXAMPLE.   A  1.2.3.1
9925 HOST-1.EXAMPLE.   MX 0 .
9926 HOST-2.EXAMPLE.   A  1.2.3.2
9927 HOST-2.EXAMPLE.   MX 0 .
9928 HOST-3.EXAMPLE.   A  1.2.3.3
9929 HOST-3.EXAMPLE.   MX 0 .
9930 ...
9931 HOST-127.EXAMPLE. A  1.2.3.127
9932 HOST-127.EXAMPLE. MX 0 .
9933 </pre>
9934 <div class="informaltable"><table border="1">
9935 <colgroup>
9936 <col>
9937 <col>
9938 </colgroup>
9939 <tbody>
9940 <tr>
9941 <td>
9942                     <p><span><strong class="command">range</strong></span></p>
9943                   </td>
9944 <td>
9945                     <p>
9946                       This can be one of two forms: start-stop
9947                       or start-stop/step. If the first form is used, then step
9948                       is set to 1. start, stop and step must be positive
9949                       integers between 0 and (2^31)-1. start must not be
9950                       larger than stop.
9951                     </p>
9952                   </td>
9953 </tr>
9954 <tr>
9955 <td>
9956                     <p><span><strong class="command">lhs</strong></span></p>
9957                   </td>
9958 <td>
9959                     <p>This
9960                       describes the owner name of the resource records
9961                       to be created.  Any single <span><strong class="command">$</strong></span>
9962                       (dollar sign)
9963                       symbols within the <span><strong class="command">lhs</strong></span> string
9964                       are replaced by the iterator value.
9965
9966                       To get a $ in the output, you need to escape the
9967                       <span><strong class="command">$</strong></span> using a backslash
9968                       <span><strong class="command">\</strong></span>,
9969                       e.g. <span><strong class="command">\$</strong></span>. The
9970                       <span><strong class="command">$</strong></span> may optionally be followed
9971                       by modifiers which change the offset from the
9972                       iterator, field width and base.
9973
9974                       Modifiers are introduced by a
9975                       <span><strong class="command">{</strong></span> (left brace) immediately following the
9976                       <span><strong class="command">$</strong></span> as
9977                       <span><strong class="command">${offset[,width[,base]]}</strong></span>.
9978                       For example, <span><strong class="command">${-20,3,d}</strong></span>
9979                       subtracts 20 from the current value, prints the
9980                       result as a decimal in a zero-padded field of
9981                       width 3.
9982
9983                       Available output forms are decimal
9984                       (<span><strong class="command">d</strong></span>), octal
9985                       (<span><strong class="command">o</strong></span>), hexadecimal
9986                       (<span><strong class="command">x</strong></span> or <span><strong class="command">X</strong></span>
9987                       for uppercase) and nibble
9988                       (<span><strong class="command">n</strong></span> or <span><strong class="command">N</strong></span>\
9989                       for uppercase).  The default modifier is
9990                       <span><strong class="command">${0,0,d}</strong></span>.  If the
9991                       <span><strong class="command">lhs</strong></span> is not absolute, the
9992                       current <span><strong class="command">$ORIGIN</strong></span> is appended
9993                       to the name.
9994                     </p>
9995                     <p>
9996                       In nibble mode the value will be treated as
9997                       if it was a reversed hexadecimal string
9998                       with each hexadecimal digit as a separate
9999                       label.  The width field includes the label
10000                       separator.
10001                     </p>
10002                     <p>
10003                       For compatibility with earlier versions,
10004                       <span><strong class="command">$$</strong></span> is still recognized as
10005                       indicating a literal $ in the output.
10006                     </p>
10007                   </td>
10008 </tr>
10009 <tr>
10010 <td>
10011                     <p><span><strong class="command">ttl</strong></span></p>
10012                   </td>
10013 <td>
10014                     <p>
10015                       Specifies the time-to-live of the generated records. If
10016                       not specified this will be inherited using the
10017                       normal TTL inheritance rules.
10018                     </p>
10019                     <p><span><strong class="command">class</strong></span>
10020                       and <span><strong class="command">ttl</strong></span> can be
10021                       entered in either order.
10022                     </p>
10023                   </td>
10024 </tr>
10025 <tr>
10026 <td>
10027                     <p><span><strong class="command">class</strong></span></p>
10028                   </td>
10029 <td>
10030                     <p>
10031                       Specifies the class of the generated records.
10032                       This must match the zone class if it is
10033                       specified.
10034                     </p>
10035                     <p><span><strong class="command">class</strong></span>
10036                       and <span><strong class="command">ttl</strong></span> can be
10037                       entered in either order.
10038                     </p>
10039                   </td>
10040 </tr>
10041 <tr>
10042 <td>
10043                     <p><span><strong class="command">type</strong></span></p>
10044                   </td>
10045 <td>
10046                     <p>
10047                       Any valid type.
10048                     </p>
10049                   </td>
10050 </tr>
10051 <tr>
10052 <td>
10053                     <p><span><strong class="command">rhs</strong></span></p>
10054                   </td>
10055 <td>
10056                     <p>
10057                       <span><strong class="command">rhs</strong></span>, optionally, quoted string.
10058                     </p>
10059                   </td>
10060 </tr>
10061 </tbody>
10062 </table></div>
10063 <p>
10064             The <span><strong class="command">$GENERATE</strong></span> directive is a <acronym class="acronym">BIND</acronym> extension
10065             and not part of the standard zone file format.
10066           </p>
10067 <p>
10068             BIND 8 does not support the optional TTL and CLASS fields.
10069           </p>
10070 </div>
10071 <div class="sect2" lang="en">
10072 <div class="titlepage"><div><div><h3 class="title">
10073 <a name="zonefile_format"></a>Additional File Formats</h3></div></div></div>
10074 <p>
10075             In addition to the standard textual format, BIND 9
10076             supports the ability to read or dump to zone files in
10077             other formats.  The <code class="constant">raw</code> format is
10078             currently available as an additional format.  It is a
10079             binary format representing BIND 9's internal data
10080             structure directly, thereby remarkably improving the
10081             loading time.
10082           </p>
10083 <p>
10084             For a primary server, a zone file in the
10085             <code class="constant">raw</code> format is expected to be
10086             generated from a textual zone file by the
10087             <span><strong class="command">named-compilezone</strong></span> command.  For a
10088             secondary server or for a dynamic zone, it is automatically
10089             generated (if this format is specified by the
10090             <span><strong class="command">masterfile-format</strong></span> option) when
10091             <span><strong class="command">named</strong></span> dumps the zone contents after
10092             zone transfer or when applying prior updates.
10093           </p>
10094 <p>
10095             If a zone file in a binary format needs manual modification,
10096             it first must be converted to a textual form by the
10097             <span><strong class="command">named-compilezone</strong></span> command.  All
10098             necessary modification should go to the text file, which
10099             should then be converted to the binary form by the
10100             <span><strong class="command">named-compilezone</strong></span> command again.
10101           </p>
10102 <p>
10103              Although the <code class="constant">raw</code> format uses the
10104              network byte order and avoids architecture-dependent
10105              data alignment so that it is as much portable as
10106              possible, it is primarily expected to be used inside
10107              the same single system.  In order to export a zone
10108              file in the <code class="constant">raw</code> format or make a
10109              portable backup of the file, it is recommended to
10110              convert the file to the standard textual representation.
10111           </p>
10112 </div>
10113 </div>
10114 <div class="sect1" lang="en">
10115 <div class="titlepage"><div><div><h2 class="title" style="clear: both">
10116 <a name="statistics"></a>BIND9 Statistics</h2></div></div></div>
10117 <p>
10118           <acronym class="acronym">BIND</acronym> 9 maintains lots of statistics
10119           information and provides several interfaces for users to
10120           get access to the statistics.
10121           The available statistics include all statistics counters
10122           that were available in <acronym class="acronym">BIND</acronym> 8 and
10123           are meaningful in <acronym class="acronym">BIND</acronym> 9,
10124           and other information that is considered useful.
10125         </p>
10126 <p>
10127           The statistics information is categorized into the following
10128           sections.
10129         </p>
10130 <div class="informaltable"><table border="1">
10131 <colgroup>
10132 <col>
10133 <col>
10134 </colgroup>
10135 <tbody>
10136 <tr>
10137 <td>
10138                   <p>Incoming Requests</p>
10139                 </td>
10140 <td>
10141                   <p>
10142                     The number of incoming DNS requests for each OPCODE.
10143                   </p>
10144                 </td>
10145 </tr>
10146 <tr>
10147 <td>
10148                   <p>Incoming Queries</p>
10149                 </td>
10150 <td>
10151                   <p>
10152                     The number of incoming queries for each RR type.
10153                   </p>
10154                 </td>
10155 </tr>
10156 <tr>
10157 <td>
10158                   <p>Outgoing Queries</p>
10159                 </td>
10160 <td>
10161                   <p>
10162                     The number of outgoing queries for each RR
10163                     type sent from the internal resolver.
10164                     Maintained per view.
10165                   </p>
10166                 </td>
10167 </tr>
10168 <tr>
10169 <td>
10170                   <p>Name Server Statistics</p>
10171                 </td>
10172 <td>
10173                   <p>
10174                     Statistics counters about incoming request processing.
10175                   </p>
10176                 </td>
10177 </tr>
10178 <tr>
10179 <td>
10180                   <p>Zone Maintenance Statistics</p>
10181                 </td>
10182 <td>
10183                   <p>
10184                     Statistics counters regarding zone maintenance
10185                     operations such as zone transfers.
10186                   </p>
10187                 </td>
10188 </tr>
10189 <tr>
10190 <td>
10191                   <p>Resolver Statistics</p>
10192                 </td>
10193 <td>
10194                   <p>
10195                     Statistics counters about name resolution
10196                     performed in the internal resolver.
10197                     Maintained per view.
10198                   </p>
10199                 </td>
10200 </tr>
10201 <tr>
10202 <td>
10203                   <p>Cache DB RRsets</p>
10204                 </td>
10205 <td>
10206                   <p>
10207                     The number of RRsets per RR type and nonexistent
10208                     names stored in the cache database.
10209                     If the exclamation mark (!) is printed for a RR
10210                     type, it means that particular type of RRset is
10211                     known to be nonexistent (this is also known as
10212                     "NXRRSET").
10213                     Maintained per view.
10214                   </p>
10215                 </td>
10216 </tr>
10217 <tr>
10218 <td>
10219                   <p>Socket I/O Statistics</p>
10220                 </td>
10221 <td>
10222                   <p>
10223                     Statistics counters about network related events.
10224                   </p>
10225                 </td>
10226 </tr>
10227 </tbody>
10228 </table></div>
10229 <p>
10230           A subset of Name Server Statistics is collected and shown
10231           per zone for which the server has the authority when
10232           <span><strong class="command">zone-statistics</strong></span> is set to
10233           <strong class="userinput"><code>yes</code></strong>.
10234           These statistics counters are shown with their zone and view
10235           names.
10236           In some cases the view names are omitted for the default view.
10237         </p>
10238 <p>
10239           There are currently two user interfaces to get access to the
10240           statistics.
10241           One is in the plain text format dumped to the file specified
10242           by the <span><strong class="command">statistics-file</strong></span> configuration option.
10243           The other is remotely accessible via a statistics channel
10244           when the <span><strong class="command">statistics-channels</strong></span> statement
10245           is specified in the configuration file
10246           (see <a href="Bv9ARM.ch06.html#statschannels" title="statistics-channels Statement Grammar">the section called &#8220;<span><strong class="command">statistics-channels</strong></span> Statement Grammar&#8221;</a>.)
10247         </p>
10248 <div class="sect3" lang="en">
10249 <div class="titlepage"><div><div><h4 class="title">
10250 <a name="statsfile"></a>The Statistics File</h4></div></div></div>
10251 <p>
10252             The text format statistics dump begins with a line, like:
10253           </p>
10254 <p>
10255             <span><strong class="command">+++ Statistics Dump +++ (973798949)</strong></span>
10256           </p>
10257 <p>
10258             The number in parentheses is a standard
10259             Unix-style timestamp, measured as seconds since January 1, 1970.
10260
10261             Following
10262             that line is a set of statistics information, which is categorized
10263             as described above.
10264             Each section begins with a line, like:
10265           </p>
10266 <p>
10267             <span><strong class="command">++ Name Server Statistics ++</strong></span>
10268           </p>
10269 <p>
10270             Each section consists of lines, each containing the statistics
10271             counter value followed by its textual description.
10272             See below for available counters.
10273             For brevity, counters that have a value of 0 are not shown
10274             in the statistics file.
10275           </p>
10276 <p>
10277             The statistics dump ends with the line where the
10278             number is identical to the number in the beginning line; for example:
10279           </p>
10280 <p>
10281             <span><strong class="command">--- Statistics Dump --- (973798949)</strong></span>
10282           </p>
10283 </div>
10284 <div class="sect2" lang="en">
10285 <div class="titlepage"><div><div><h3 class="title">
10286 <a name="statistics_counters"></a>Statistics Counters</h3></div></div></div>
10287 <p>
10288             The following tables summarize statistics counters that
10289             <acronym class="acronym">BIND</acronym> 9 provides.
10290             For each row of the tables, the leftmost column is the
10291             abbreviated symbol name of that counter.
10292             These symbols are shown in the statistics information
10293             accessed via an HTTP statistics channel.
10294             The rightmost column gives the description of the counter,
10295             which is also shown in the statistics file
10296             (but, in this document, possibly with slight modification
10297             for better readability).
10298             Additional notes may also be provided in this column.
10299             When a middle column exists between these two columns,
10300             it gives the corresponding counter name of the
10301             <acronym class="acronym">BIND</acronym> 8 statistics, if applicable.
10302           </p>
10303 <div class="sect3" lang="en">
10304 <div class="titlepage"><div><div><h4 class="title">
10305 <a name="id2600941"></a>Name Server Statistics Counters</h4></div></div></div>
10306 <div class="informaltable"><table border="1">
10307 <colgroup>
10308 <col>
10309 <col>
10310 <col>
10311 </colgroup>
10312 <tbody>
10313 <tr>
10314 <td>
10315                       <p>
10316                         <span class="emphasis"><em>Symbol</em></span>
10317                       </p>
10318                     </td>
10319 <td>
10320                       <p>
10321                         <span class="emphasis"><em>BIND8 Symbol</em></span>
10322                       </p>
10323                     </td>
10324 <td>
10325                       <p>
10326                         <span class="emphasis"><em>Description</em></span>
10327                       </p>
10328                     </td>
10329 </tr>
10330 <tr>
10331 <td>
10332                       <p><span><strong class="command">Requestv4</strong></span></p>
10333                     </td>
10334 <td>
10335                       <p><span><strong class="command">RQ</strong></span></p>
10336                     </td>
10337 <td>
10338                       <p>
10339                         IPv4 requests received.
10340                         Note: this also counts non query requests.
10341                       </p>
10342                     </td>
10343 </tr>
10344 <tr>
10345 <td>
10346                       <p><span><strong class="command">Requestv6</strong></span></p>
10347                     </td>
10348 <td>
10349                       <p><span><strong class="command">RQ</strong></span></p>
10350                     </td>
10351 <td>
10352                       <p>
10353                         IPv6 requests received.
10354                         Note: this also counts non query requests.
10355                       </p>
10356                     </td>
10357 </tr>
10358 <tr>
10359 <td>
10360                       <p><span><strong class="command">ReqEdns0</strong></span></p>
10361                     </td>
10362 <td>
10363                       <p><span><strong class="command"></strong></span></p>
10364                     </td>
10365 <td>
10366                       <p>
10367                         Requests with EDNS(0) received.
10368                       </p>
10369                     </td>
10370 </tr>
10371 <tr>
10372 <td>
10373                       <p><span><strong class="command">ReqBadEDNSVer</strong></span></p>
10374                     </td>
10375 <td>
10376                       <p><span><strong class="command"></strong></span></p>
10377                     </td>
10378 <td>
10379                       <p>
10380                         Requests with unsupported EDNS version received.
10381                       </p>
10382                     </td>
10383 </tr>
10384 <tr>
10385 <td>
10386                       <p><span><strong class="command">ReqTSIG</strong></span></p>
10387                     </td>
10388 <td>
10389                       <p><span><strong class="command"></strong></span></p>
10390                     </td>
10391 <td>
10392                       <p>
10393                         Requests with TSIG received.
10394                       </p>
10395                     </td>
10396 </tr>
10397 <tr>
10398 <td>
10399                       <p><span><strong class="command">ReqSIG0</strong></span></p>
10400                     </td>
10401 <td>
10402                       <p><span><strong class="command"></strong></span></p>
10403                     </td>
10404 <td>
10405                       <p>
10406                         Requests with SIG(0) received.
10407                       </p>
10408                     </td>
10409 </tr>
10410 <tr>
10411 <td>
10412                       <p><span><strong class="command">ReqBadSIG</strong></span></p>
10413                     </td>
10414 <td>
10415                       <p><span><strong class="command"></strong></span></p>
10416                     </td>
10417 <td>
10418                       <p>
10419                         Requests with invalid (TSIG or SIG(0)) signature.
10420                       </p>
10421                     </td>
10422 </tr>
10423 <tr>
10424 <td>
10425                       <p><span><strong class="command">ReqTCP</strong></span></p>
10426                     </td>
10427 <td>
10428                       <p><span><strong class="command">RTCP</strong></span></p>
10429                     </td>
10430 <td>
10431                       <p>
10432                         TCP requests received.
10433                       </p>
10434                     </td>
10435 </tr>
10436 <tr>
10437 <td>
10438                       <p><span><strong class="command">AuthQryRej</strong></span></p>
10439                     </td>
10440 <td>
10441                       <p><span><strong class="command">RUQ</strong></span></p>
10442                     </td>
10443 <td>
10444                       <p>
10445                         Authoritative (non recursive) queries rejected.
10446                       </p>
10447                     </td>
10448 </tr>
10449 <tr>
10450 <td>
10451                       <p><span><strong class="command">RecQryRej</strong></span></p>
10452                     </td>
10453 <td>
10454                       <p><span><strong class="command">RURQ</strong></span></p>
10455                     </td>
10456 <td>
10457                       <p>
10458                         Recursive queries rejected.
10459                       </p>
10460                     </td>
10461 </tr>
10462 <tr>
10463 <td>
10464                       <p><span><strong class="command">XfrRej</strong></span></p>
10465                     </td>
10466 <td>
10467                       <p><span><strong class="command">RUXFR</strong></span></p>
10468                     </td>
10469 <td>
10470                       <p>
10471                         Zone transfer requests rejected.
10472                       </p>
10473                     </td>
10474 </tr>
10475 <tr>
10476 <td>
10477                       <p><span><strong class="command">UpdateRej</strong></span></p>
10478                     </td>
10479 <td>
10480                       <p><span><strong class="command">RUUpd</strong></span></p>
10481                     </td>
10482 <td>
10483                       <p>
10484                         Dynamic update requests rejected.
10485                       </p>
10486                     </td>
10487 </tr>
10488 <tr>
10489 <td>
10490                       <p><span><strong class="command">Response</strong></span></p>
10491                     </td>
10492 <td>
10493                       <p><span><strong class="command">SAns</strong></span></p>
10494                     </td>
10495 <td>
10496                       <p>
10497                         Responses sent.
10498                       </p>
10499                     </td>
10500 </tr>
10501 <tr>
10502 <td>
10503                       <p><span><strong class="command">RespTruncated</strong></span></p>
10504                     </td>
10505 <td>
10506                       <p><span><strong class="command"></strong></span></p>
10507                     </td>
10508 <td>
10509                       <p>
10510                         Truncated responses sent.
10511                       </p>
10512                     </td>
10513 </tr>
10514 <tr>
10515 <td>
10516                       <p><span><strong class="command">RespEDNS0</strong></span></p>
10517                     </td>
10518 <td>
10519                       <p><span><strong class="command"></strong></span></p>
10520                     </td>
10521 <td>
10522                       <p>
10523                         Responses with EDNS(0) sent.
10524                       </p>
10525                     </td>
10526 </tr>
10527 <tr>
10528 <td>
10529                       <p><span><strong class="command">RespTSIG</strong></span></p>
10530                     </td>
10531 <td>
10532                       <p><span><strong class="command"></strong></span></p>
10533                     </td>
10534 <td>
10535                       <p>
10536                         Responses with TSIG sent.
10537                       </p>
10538                     </td>
10539 </tr>
10540 <tr>
10541 <td>
10542                       <p><span><strong class="command">RespSIG0</strong></span></p>
10543                     </td>
10544 <td>
10545                       <p><span><strong class="command"></strong></span></p>
10546                     </td>
10547 <td>
10548                       <p>
10549                         Responses with SIG(0) sent.
10550                       </p>
10551                     </td>
10552 </tr>
10553 <tr>
10554 <td>
10555                       <p><span><strong class="command">QrySuccess</strong></span></p>
10556                     </td>
10557 <td>
10558                       <p><span><strong class="command"></strong></span></p>
10559                     </td>
10560 <td>
10561                       <p>
10562                         Queries resulted in a successful answer.
10563                         This means the query which returns a NOERROR response
10564                         with at least one answer RR.
10565                         This corresponds to the
10566                         <span><strong class="command">success</strong></span> counter
10567                         of previous versions of
10568                         <acronym class="acronym">BIND</acronym> 9.
10569                       </p>
10570                     </td>
10571 </tr>
10572 <tr>
10573 <td>
10574                       <p><span><strong class="command">QryAuthAns</strong></span></p>
10575                     </td>
10576 <td>
10577                       <p><span><strong class="command"></strong></span></p>
10578                     </td>
10579 <td>
10580                       <p>
10581                         Queries resulted in authoritative answer.
10582                       </p>
10583                     </td>
10584 </tr>
10585 <tr>
10586 <td>
10587                       <p><span><strong class="command">QryNoauthAns</strong></span></p>
10588                     </td>
10589 <td>
10590                       <p><span><strong class="command">SNaAns</strong></span></p>
10591                     </td>
10592 <td>
10593                       <p>
10594                         Queries resulted in non authoritative answer.
10595                       </p>
10596                     </td>
10597 </tr>
10598 <tr>
10599 <td>
10600                       <p><span><strong class="command">QryReferral</strong></span></p>
10601                     </td>
10602 <td>
10603                       <p><span><strong class="command"></strong></span></p>
10604                     </td>
10605 <td>
10606                       <p>
10607                         Queries resulted in referral answer.
10608                         This corresponds to the
10609                         <span><strong class="command">referral</strong></span> counter
10610                         of previous versions of
10611                         <acronym class="acronym">BIND</acronym> 9.
10612                       </p>
10613                     </td>
10614 </tr>
10615 <tr>
10616 <td>
10617                       <p><span><strong class="command">QryNxrrset</strong></span></p>
10618                     </td>
10619 <td>
10620                       <p><span><strong class="command"></strong></span></p>
10621                     </td>
10622 <td>
10623                       <p>
10624                         Queries resulted in NOERROR responses with no data.
10625                         This corresponds to the
10626                         <span><strong class="command">nxrrset</strong></span> counter
10627                         of previous versions of
10628                         <acronym class="acronym">BIND</acronym> 9.
10629                       </p>
10630                     </td>
10631 </tr>
10632 <tr>
10633 <td>
10634                       <p><span><strong class="command">QrySERVFAIL</strong></span></p>
10635                     </td>
10636 <td>
10637                       <p><span><strong class="command">SFail</strong></span></p>
10638                     </td>
10639 <td>
10640                       <p>
10641                         Queries resulted in SERVFAIL.
10642                       </p>
10643                     </td>
10644 </tr>
10645 <tr>
10646 <td>
10647                       <p><span><strong class="command">QryFORMERR</strong></span></p>
10648                     </td>
10649 <td>
10650                       <p><span><strong class="command">SFErr</strong></span></p>
10651                     </td>
10652 <td>
10653                       <p>
10654                         Queries resulted in FORMERR.
10655                       </p>
10656                     </td>
10657 </tr>
10658 <tr>
10659 <td>
10660                       <p><span><strong class="command">QryNXDOMAIN</strong></span></p>
10661                     </td>
10662 <td>
10663                       <p><span><strong class="command">SNXD</strong></span></p>
10664                     </td>
10665 <td>
10666                       <p>
10667                         Queries resulted in NXDOMAIN.
10668                         This corresponds to the
10669                         <span><strong class="command">nxdomain</strong></span> counter
10670                         of previous versions of
10671                         <acronym class="acronym">BIND</acronym> 9.
10672                       </p>
10673                     </td>
10674 </tr>
10675 <tr>
10676 <td>
10677                       <p><span><strong class="command">QryRecursion</strong></span></p>
10678                     </td>
10679 <td>
10680                       <p><span><strong class="command">RFwdQ</strong></span></p>
10681                     </td>
10682 <td>
10683                       <p>
10684                         Queries which caused the server
10685                         to perform recursion in order to find the final answer.
10686                         This corresponds to the
10687                         <span><strong class="command">recursion</strong></span> counter
10688                         of previous versions of
10689                         <acronym class="acronym">BIND</acronym> 9.
10690                       </p>
10691                     </td>
10692 </tr>
10693 <tr>
10694 <td>
10695                       <p><span><strong class="command">QryDuplicate</strong></span></p>
10696                     </td>
10697 <td>
10698                       <p><span><strong class="command">RDupQ</strong></span></p>
10699                     </td>
10700 <td>
10701                       <p>
10702                         Queries which the server attempted to
10703                         recurse but discovered an existing query with the same
10704                         IP address, port, query ID, name, type and class
10705                         already being processed.
10706                         This corresponds to the
10707                         <span><strong class="command">duplicate</strong></span> counter
10708                         of previous versions of
10709                         <acronym class="acronym">BIND</acronym> 9.
10710                       </p>
10711                     </td>
10712 </tr>
10713 <tr>
10714 <td>
10715                       <p><span><strong class="command">QryDropped</strong></span></p>
10716                     </td>
10717 <td>
10718                       <p><span><strong class="command"></strong></span></p>
10719                     </td>
10720 <td>
10721                       <p>
10722                         Recursive queries for which the server
10723                         discovered an excessive number of existing
10724                         recursive queries for the same name, type and
10725                         class and were subsequently dropped.
10726                         This is the number of dropped queries due to
10727                         the reason explained with the
10728                         <span><strong class="command">clients-per-query</strong></span>
10729                         and
10730                         <span><strong class="command">max-clients-per-query</strong></span>
10731                         options
10732                         (see the description about
10733                         <a href="Bv9ARM.ch06.html#clients-per-query"><span><strong class="command">clients-per-query</strong></span></a>.)
10734                         This corresponds to the
10735                         <span><strong class="command">dropped</strong></span> counter
10736                         of previous versions of
10737                         <acronym class="acronym">BIND</acronym> 9.
10738                       </p>
10739                     </td>
10740 </tr>
10741 <tr>
10742 <td>
10743                       <p><span><strong class="command">QryFailure</strong></span></p>
10744                     </td>
10745 <td>
10746                       <p><span><strong class="command"></strong></span></p>
10747                     </td>
10748 <td>
10749                       <p>
10750                         Other query failures.
10751                         This corresponds to the
10752                         <span><strong class="command">failure</strong></span> counter
10753                         of previous versions of
10754                         <acronym class="acronym">BIND</acronym> 9.
10755                         Note: this counter is provided mainly for
10756                         backward compatibility with the previous versions.
10757                         Normally a more fine-grained counters such as
10758                         <span><strong class="command">AuthQryRej</strong></span> and
10759                         <span><strong class="command">RecQryRej</strong></span>
10760                         that would also fall into this counter are provided,
10761                         and so this counter would not be of much
10762                         interest in practice.
10763                       </p>
10764                     </td>
10765 </tr>
10766 <tr>
10767 <td>
10768                       <p><span><strong class="command">XfrReqDone</strong></span></p>
10769                     </td>
10770 <td>
10771                       <p><span><strong class="command"></strong></span></p>
10772                     </td>
10773 <td>
10774                       <p>
10775                         Requested zone transfers completed.
10776                       </p>
10777                     </td>
10778 </tr>
10779 <tr>
10780 <td>
10781                       <p><span><strong class="command">UpdateReqFwd</strong></span></p>
10782                     </td>
10783 <td>
10784                       <p><span><strong class="command"></strong></span></p>
10785                     </td>
10786 <td>
10787                       <p>
10788                         Update requests forwarded.
10789                       </p>
10790                     </td>
10791 </tr>
10792 <tr>
10793 <td>
10794                       <p><span><strong class="command">UpdateRespFwd</strong></span></p>
10795                     </td>
10796 <td>
10797                       <p><span><strong class="command"></strong></span></p>
10798                     </td>
10799 <td>
10800                       <p>
10801                         Update responses forwarded.
10802                       </p>
10803                     </td>
10804 </tr>
10805 <tr>
10806 <td>
10807                       <p><span><strong class="command">UpdateFwdFail</strong></span></p>
10808                     </td>
10809 <td>
10810                       <p><span><strong class="command"></strong></span></p>
10811                     </td>
10812 <td>
10813                       <p>
10814                         Dynamic update forward failed.
10815                       </p>
10816                     </td>
10817 </tr>
10818 <tr>
10819 <td>
10820                       <p><span><strong class="command">UpdateDone</strong></span></p>
10821                     </td>
10822 <td>
10823                       <p><span><strong class="command"></strong></span></p>
10824                     </td>
10825 <td>
10826                       <p>
10827                         Dynamic updates completed.
10828                       </p>
10829                     </td>
10830 </tr>
10831 <tr>
10832 <td>
10833                       <p><span><strong class="command">UpdateFail</strong></span></p>
10834                     </td>
10835 <td>
10836                       <p><span><strong class="command"></strong></span></p>
10837                     </td>
10838 <td>
10839                       <p>
10840                         Dynamic updates failed.
10841                       </p>
10842                     </td>
10843 </tr>
10844 <tr>
10845 <td>
10846                       <p><span><strong class="command">UpdateBadPrereq</strong></span></p>
10847                     </td>
10848 <td>
10849                       <p><span><strong class="command"></strong></span></p>
10850                     </td>
10851 <td>
10852                       <p>
10853                         Dynamic updates rejected due to prerequisite failure.
10854                       </p>
10855                     </td>
10856 </tr>
10857 <tr>
10858 <td>
10859                       <p><span><strong class="command">RPZRewrites</strong></span></p>
10860                     </td>
10861 <td>
10862                       <p><span><strong class="command"></strong></span></p>
10863                     </td>
10864 <td>
10865                       <p>
10866                         Response policy zone rewrites.
10867                       </p>
10868                     </td>
10869 </tr>
10870 <tr>
10871 <td>
10872                       <p><span><strong class="command">RateDropped</strong></span></p>
10873                     </td>
10874 <td>
10875                       <p><span><strong class="command"></strong></span></p>
10876                     </td>
10877 <td>
10878                       <p>
10879                         Responses dropped by rate limits.
10880                       </p>
10881                     </td>
10882 </tr>
10883 <tr>
10884 <td>
10885                       <p><span><strong class="command">RateSlipped</strong></span></p>
10886                     </td>
10887 <td>
10888                       <p><span><strong class="command"></strong></span></p>
10889                     </td>
10890 <td>
10891                       <p>
10892                         Responses truncated by rate limits.
10893                       </p>
10894                     </td>
10895 </tr>
10896 </tbody>
10897 </table></div>
10898 </div>
10899 <div class="sect3" lang="en">
10900 <div class="titlepage"><div><div><h4 class="title">
10901 <a name="id2602510"></a>Zone Maintenance Statistics Counters</h4></div></div></div>
10902 <div class="informaltable"><table border="1">
10903 <colgroup>
10904 <col>
10905 <col>
10906 </colgroup>
10907 <tbody>
10908 <tr>
10909 <td>
10910                       <p>
10911                         <span class="emphasis"><em>Symbol</em></span>
10912                       </p>
10913                     </td>
10914 <td>
10915                       <p>
10916                         <span class="emphasis"><em>Description</em></span>
10917                       </p>
10918                     </td>
10919 </tr>
10920 <tr>
10921 <td>
10922                       <p><span><strong class="command">NotifyOutv4</strong></span></p>
10923                     </td>
10924 <td>
10925                       <p>
10926                         IPv4 notifies sent.
10927                       </p>
10928                     </td>
10929 </tr>
10930 <tr>
10931 <td>
10932                       <p><span><strong class="command">NotifyOutv6</strong></span></p>
10933                     </td>
10934 <td>
10935                       <p>
10936                         IPv6 notifies sent.
10937                       </p>
10938                     </td>
10939 </tr>
10940 <tr>
10941 <td>
10942                       <p><span><strong class="command">NotifyInv4</strong></span></p>
10943                     </td>
10944 <td>
10945                       <p>
10946                         IPv4 notifies received.
10947                       </p>
10948                     </td>
10949 </tr>
10950 <tr>
10951 <td>
10952                       <p><span><strong class="command">NotifyInv6</strong></span></p>
10953                     </td>
10954 <td>
10955                       <p>
10956                         IPv6 notifies received.
10957                       </p>
10958                     </td>
10959 </tr>
10960 <tr>
10961 <td>
10962                       <p><span><strong class="command">NotifyRej</strong></span></p>
10963                     </td>
10964 <td>
10965                       <p>
10966                         Incoming notifies rejected.
10967                       </p>
10968                     </td>
10969 </tr>
10970 <tr>
10971 <td>
10972                       <p><span><strong class="command">SOAOutv4</strong></span></p>
10973                     </td>
10974 <td>
10975                       <p>
10976                         IPv4 SOA queries sent.
10977                       </p>
10978                     </td>
10979 </tr>
10980 <tr>
10981 <td>
10982                       <p><span><strong class="command">SOAOutv6</strong></span></p>
10983                     </td>
10984 <td>
10985                       <p>
10986                         IPv6 SOA queries sent.
10987                       </p>
10988                     </td>
10989 </tr>
10990 <tr>
10991 <td>
10992                       <p><span><strong class="command">AXFRReqv4</strong></span></p>
10993                     </td>
10994 <td>
10995                       <p>
10996                         IPv4 AXFR requested.
10997                       </p>
10998                     </td>
10999 </tr>
11000 <tr>
11001 <td>
11002                       <p><span><strong class="command">AXFRReqv6</strong></span></p>
11003                     </td>
11004 <td>
11005                       <p>
11006                         IPv6 AXFR requested.
11007                       </p>
11008                     </td>
11009 </tr>
11010 <tr>
11011 <td>
11012                       <p><span><strong class="command">IXFRReqv4</strong></span></p>
11013                     </td>
11014 <td>
11015                       <p>
11016                         IPv4 IXFR requested.
11017                       </p>
11018                     </td>
11019 </tr>
11020 <tr>
11021 <td>
11022                       <p><span><strong class="command">IXFRReqv6</strong></span></p>
11023                     </td>
11024 <td>
11025                       <p>
11026                         IPv6 IXFR requested.
11027                       </p>
11028                     </td>
11029 </tr>
11030 <tr>
11031 <td>
11032                       <p><span><strong class="command">XfrSuccess</strong></span></p>
11033                     </td>
11034 <td>
11035                       <p>
11036                         Zone transfer requests succeeded.
11037                       </p>
11038                     </td>
11039 </tr>
11040 <tr>
11041 <td>
11042                       <p><span><strong class="command">XfrFail</strong></span></p>
11043                     </td>
11044 <td>
11045                       <p>
11046                         Zone transfer requests failed.
11047                       </p>
11048                     </td>
11049 </tr>
11050 </tbody>
11051 </table></div>
11052 </div>
11053 <div class="sect3" lang="en">
11054 <div class="titlepage"><div><div><h4 class="title">
11055 <a name="id2602962"></a>Resolver Statistics Counters</h4></div></div></div>
11056 <div class="informaltable"><table border="1">
11057 <colgroup>
11058 <col>
11059 <col>
11060 <col>
11061 </colgroup>
11062 <tbody>
11063 <tr>
11064 <td>
11065                       <p>
11066                         <span class="emphasis"><em>Symbol</em></span>
11067                       </p>
11068                     </td>
11069 <td>
11070                       <p>
11071                         <span class="emphasis"><em>BIND8 Symbol</em></span>
11072                       </p>
11073                     </td>
11074 <td>
11075                       <p>
11076                         <span class="emphasis"><em>Description</em></span>
11077                       </p>
11078                     </td>
11079 </tr>
11080 <tr>
11081 <td>
11082                       <p><span><strong class="command">Queryv4</strong></span></p>
11083                     </td>
11084 <td>
11085                       <p><span><strong class="command">SFwdQ</strong></span></p>
11086                     </td>
11087 <td>
11088                       <p>
11089                         IPv4 queries sent.
11090                       </p>
11091                     </td>
11092 </tr>
11093 <tr>
11094 <td>
11095                       <p><span><strong class="command">Queryv6</strong></span></p>
11096                     </td>
11097 <td>
11098                       <p><span><strong class="command">SFwdQ</strong></span></p>
11099                     </td>
11100 <td>
11101                       <p>
11102                         IPv6 queries sent.
11103                       </p>
11104                     </td>
11105 </tr>
11106 <tr>
11107 <td>
11108                       <p><span><strong class="command">Responsev4</strong></span></p>
11109                     </td>
11110 <td>
11111                       <p><span><strong class="command">RR</strong></span></p>
11112                     </td>
11113 <td>
11114                       <p>
11115                         IPv4 responses received.
11116                       </p>
11117                     </td>
11118 </tr>
11119 <tr>
11120 <td>
11121                       <p><span><strong class="command">Responsev6</strong></span></p>
11122                     </td>
11123 <td>
11124                       <p><span><strong class="command">RR</strong></span></p>
11125                     </td>
11126 <td>
11127                       <p>
11128                         IPv6 responses received.
11129                       </p>
11130                     </td>
11131 </tr>
11132 <tr>
11133 <td>
11134                       <p><span><strong class="command">NXDOMAIN</strong></span></p>
11135                     </td>
11136 <td>
11137                       <p><span><strong class="command">RNXD</strong></span></p>
11138                     </td>
11139 <td>
11140                       <p>
11141                         NXDOMAIN received.
11142                       </p>
11143                     </td>
11144 </tr>
11145 <tr>
11146 <td>
11147                       <p><span><strong class="command">SERVFAIL</strong></span></p>
11148                     </td>
11149 <td>
11150                       <p><span><strong class="command">RFail</strong></span></p>
11151                     </td>
11152 <td>
11153                       <p>
11154                         SERVFAIL received.
11155                       </p>
11156                     </td>
11157 </tr>
11158 <tr>
11159 <td>
11160                       <p><span><strong class="command">FORMERR</strong></span></p>
11161                     </td>
11162 <td>
11163                       <p><span><strong class="command">RFErr</strong></span></p>
11164                     </td>
11165 <td>
11166                       <p>
11167                         FORMERR received.
11168                       </p>
11169                     </td>
11170 </tr>
11171 <tr>
11172 <td>
11173                       <p><span><strong class="command">OtherError</strong></span></p>
11174                     </td>
11175 <td>
11176                       <p><span><strong class="command">RErr</strong></span></p>
11177                     </td>
11178 <td>
11179                       <p>
11180                         Other errors received.
11181                       </p>
11182                     </td>
11183 </tr>
11184 <tr>
11185 <td>
11186                       <p><span><strong class="command">EDNS0Fail</strong></span></p>
11187                                                  </td>
11188 <td>
11189                       <p><span><strong class="command"></strong></span></p>
11190                     </td>
11191 <td>
11192                       <p>
11193                         EDNS(0) query failures.
11194                       </p>
11195                     </td>
11196 </tr>
11197 <tr>
11198 <td>
11199                       <p><span><strong class="command">Mismatch</strong></span></p>
11200                     </td>
11201 <td>
11202                       <p><span><strong class="command">RDupR</strong></span></p>
11203                     </td>
11204 <td>
11205                       <p>
11206                         Mismatch responses received.
11207                         The DNS ID, response's source address,
11208                         and/or the response's source port does not
11209                         match what was expected.
11210                         (The port must be 53 or as defined by
11211                         the <span><strong class="command">port</strong></span> option.)
11212                         This may be an indication of a cache
11213                         poisoning attempt.
11214                       </p>
11215                     </td>
11216 </tr>
11217 <tr>
11218 <td>
11219                       <p><span><strong class="command">Truncated</strong></span></p>
11220                     </td>
11221 <td>
11222                       <p><span><strong class="command"></strong></span></p>
11223                     </td>
11224 <td>
11225                       <p>
11226                         Truncated responses received.
11227                       </p>
11228                     </td>
11229 </tr>
11230 <tr>
11231 <td>
11232                       <p><span><strong class="command">Lame</strong></span></p>
11233                     </td>
11234 <td>
11235                       <p><span><strong class="command">RLame</strong></span></p>
11236                     </td>
11237 <td>
11238                       <p>
11239                         Lame delegations received.
11240                       </p>
11241                     </td>
11242 </tr>
11243 <tr>
11244 <td>
11245                       <p><span><strong class="command">Retry</strong></span></p>
11246                     </td>
11247 <td>
11248                       <p><span><strong class="command">SDupQ</strong></span></p>
11249                     </td>
11250 <td>
11251                       <p>
11252                         Query retries performed.
11253                       </p>
11254                     </td>
11255 </tr>
11256 <tr>
11257 <td>
11258                       <p><span><strong class="command">QueryAbort</strong></span></p>
11259                     </td>
11260 <td>
11261                       <p><span><strong class="command"></strong></span></p>
11262                     </td>
11263 <td>
11264                       <p>
11265                         Queries aborted due to quota control.
11266                       </p>
11267                     </td>
11268 </tr>
11269 <tr>
11270 <td>
11271                       <p><span><strong class="command">QuerySockFail</strong></span></p>
11272                     </td>
11273 <td>
11274                       <p><span><strong class="command"></strong></span></p>
11275                     </td>
11276 <td>
11277                       <p>
11278                         Failures in opening query sockets.
11279                         One common reason for such failures is a
11280                         failure of opening a new socket due to a
11281                         limitation on file descriptors.
11282                       </p>
11283                     </td>
11284 </tr>
11285 <tr>
11286 <td>
11287                       <p><span><strong class="command">QueryTimeout</strong></span></p>
11288                     </td>
11289 <td>
11290                       <p><span><strong class="command"></strong></span></p>
11291                     </td>
11292 <td>
11293                       <p>
11294                         Query timeouts.
11295                       </p>
11296                     </td>
11297 </tr>
11298 <tr>
11299 <td>
11300                       <p><span><strong class="command">GlueFetchv4</strong></span></p>
11301                     </td>
11302 <td>
11303                       <p><span><strong class="command">SSysQ</strong></span></p>
11304                     </td>
11305 <td>
11306                       <p>
11307                         IPv4 NS address fetches invoked.
11308                       </p>
11309                     </td>
11310 </tr>
11311 <tr>
11312 <td>
11313                       <p><span><strong class="command">GlueFetchv6</strong></span></p>
11314                     </td>
11315 <td>
11316                       <p><span><strong class="command">SSysQ</strong></span></p>
11317                     </td>
11318 <td>
11319                       <p>
11320                         IPv6 NS address fetches invoked.
11321                       </p>
11322                     </td>
11323 </tr>
11324 <tr>
11325 <td>
11326                       <p><span><strong class="command">GlueFetchv4Fail</strong></span></p>
11327                     </td>
11328 <td>
11329                       <p><span><strong class="command"></strong></span></p>
11330                     </td>
11331 <td>
11332                       <p>
11333                         IPv4 NS address fetch failed.
11334                       </p>
11335                     </td>
11336 </tr>
11337 <tr>
11338 <td>
11339                       <p><span><strong class="command">GlueFetchv6Fail</strong></span></p>
11340                     </td>
11341 <td>
11342                       <p><span><strong class="command"></strong></span></p>
11343                     </td>
11344 <td>
11345                       <p>
11346                         IPv6 NS address fetch failed.
11347                       </p>
11348                     </td>
11349 </tr>
11350 <tr>
11351 <td>
11352                       <p><span><strong class="command">ValAttempt</strong></span></p>
11353                     </td>
11354 <td>
11355                       <p><span><strong class="command"></strong></span></p>
11356                     </td>
11357 <td>
11358                       <p>
11359                         DNSSEC validation attempted.
11360                       </p>
11361                     </td>
11362 </tr>
11363 <tr>
11364 <td>
11365                       <p><span><strong class="command">ValOk</strong></span></p>
11366                     </td>
11367 <td>
11368                       <p><span><strong class="command"></strong></span></p>
11369                     </td>
11370 <td>
11371                       <p>
11372                         DNSSEC validation succeeded.
11373                       </p>
11374                     </td>
11375 </tr>
11376 <tr>
11377 <td>
11378                       <p><span><strong class="command">ValNegOk</strong></span></p>
11379                     </td>
11380 <td>
11381                       <p><span><strong class="command"></strong></span></p>
11382                     </td>
11383 <td>
11384                       <p>
11385                         DNSSEC validation on negative information succeeded.
11386                       </p>
11387                     </td>
11388 </tr>
11389 <tr>
11390 <td>
11391                       <p><span><strong class="command">ValFail</strong></span></p>
11392                     </td>
11393 <td>
11394                       <p><span><strong class="command"></strong></span></p>
11395                     </td>
11396 <td>
11397                       <p>
11398                         DNSSEC validation failed.
11399                       </p>
11400                     </td>
11401 </tr>
11402 <tr>
11403 <td>
11404                       <p><span><strong class="command">QryRTTnn</strong></span></p>
11405                     </td>
11406 <td>
11407                       <p><span><strong class="command"></strong></span></p>
11408                     </td>
11409 <td>
11410                       <p>
11411                         Frequency table on round trip times (RTTs) of
11412                         queries.
11413                         Each <span><strong class="command">nn</strong></span> specifies the corresponding
11414                         frequency.
11415                         In the sequence of
11416                         <span><strong class="command">nn_1</strong></span>,
11417                         <span><strong class="command">nn_2</strong></span>,
11418                         ...,
11419                         <span><strong class="command">nn_m</strong></span>,
11420                         the value of <span><strong class="command">nn_i</strong></span> is the
11421                         number of queries whose RTTs are between
11422                         <span><strong class="command">nn_(i-1)</strong></span> (inclusive) and
11423                         <span><strong class="command">nn_i</strong></span> (exclusive) milliseconds.
11424                         For the sake of convenience we define
11425                         <span><strong class="command">nn_0</strong></span> to be 0.
11426                         The last entry should be represented as
11427                         <span><strong class="command">nn_m+</strong></span>, which means the
11428                         number of queries whose RTTs are equal to or over
11429                         <span><strong class="command">nn_m</strong></span> milliseconds.
11430                       </p>
11431                     </td>
11432 </tr>
11433 </tbody>
11434 </table></div>
11435 </div>
11436 <div class="sect3" lang="en">
11437 <div class="titlepage"><div><div><h4 class="title">
11438 <a name="id2604052"></a>Socket I/O Statistics Counters</h4></div></div></div>
11439 <p>
11440               Socket I/O statistics counters are defined per socket
11441               types, which are
11442               <span><strong class="command">UDP4</strong></span> (UDP/IPv4),
11443               <span><strong class="command">UDP6</strong></span> (UDP/IPv6),
11444               <span><strong class="command">TCP4</strong></span> (TCP/IPv4),
11445               <span><strong class="command">TCP6</strong></span> (TCP/IPv6),
11446               <span><strong class="command">Unix</strong></span> (Unix Domain), and
11447               <span><strong class="command">FDwatch</strong></span> (sockets opened outside the
11448               socket module).
11449               In the following table <span><strong class="command">&lt;TYPE&gt;</strong></span>
11450               represents a socket type.
11451               Not all counters are available for all socket types;
11452               exceptions are noted in the description field.
11453             </p>
11454 <div class="informaltable"><table border="1">
11455 <colgroup>
11456 <col>
11457 <col>
11458 </colgroup>
11459 <tbody>
11460 <tr>
11461 <td>
11462                       <p>
11463                         <span class="emphasis"><em>Symbol</em></span>
11464                       </p>
11465                     </td>
11466 <td>
11467                       <p>
11468                         <span class="emphasis"><em>Description</em></span>
11469                       </p>
11470                     </td>
11471 </tr>
11472 <tr>
11473 <td>
11474                       <p><span><strong class="command">&lt;TYPE&gt;Open</strong></span></p>
11475                     </td>
11476 <td>
11477                       <p>
11478                         Sockets opened successfully.
11479                         This counter is not applicable to the
11480                         <span><strong class="command">FDwatch</strong></span> type.
11481                       </p>
11482                     </td>
11483 </tr>
11484 <tr>
11485 <td>
11486                       <p><span><strong class="command">&lt;TYPE&gt;OpenFail</strong></span></p>
11487                     </td>
11488 <td>
11489                       <p>
11490                         Failures of opening sockets.
11491                         This counter is not applicable to the
11492                         <span><strong class="command">FDwatch</strong></span> type.
11493                       </p>
11494                     </td>
11495 </tr>
11496 <tr>
11497 <td>
11498                       <p><span><strong class="command">&lt;TYPE&gt;Close</strong></span></p>
11499                     </td>
11500 <td>
11501                       <p>
11502                         Sockets closed.
11503                       </p>
11504                     </td>
11505 </tr>
11506 <tr>
11507 <td>
11508                       <p><span><strong class="command">&lt;TYPE&gt;BindFail</strong></span></p>
11509                     </td>
11510 <td>
11511                       <p>
11512                         Failures of binding sockets.
11513                       </p>
11514                     </td>
11515 </tr>
11516 <tr>
11517 <td>
11518                       <p><span><strong class="command">&lt;TYPE&gt;ConnFail</strong></span></p>
11519                     </td>
11520 <td>
11521                       <p>
11522                         Failures of connecting sockets.
11523                       </p>
11524                     </td>
11525 </tr>
11526 <tr>
11527 <td>
11528                       <p><span><strong class="command">&lt;TYPE&gt;Conn</strong></span></p>
11529                     </td>
11530 <td>
11531                       <p>
11532                         Connections established successfully.
11533                       </p>
11534                     </td>
11535 </tr>
11536 <tr>
11537 <td>
11538                       <p><span><strong class="command">&lt;TYPE&gt;AcceptFail</strong></span></p>
11539                     </td>
11540 <td>
11541                       <p>
11542                         Failures of accepting incoming connection requests.
11543                         This counter is not applicable to the
11544                         <span><strong class="command">UDP</strong></span> and
11545                         <span><strong class="command">FDwatch</strong></span> types.
11546                       </p>
11547                     </td>
11548 </tr>
11549 <tr>
11550 <td>
11551                       <p><span><strong class="command">&lt;TYPE&gt;Accept</strong></span></p>
11552                     </td>
11553 <td>
11554                       <p>
11555                         Incoming connections successfully accepted.
11556                         This counter is not applicable to the
11557                         <span><strong class="command">UDP</strong></span> and
11558                         <span><strong class="command">FDwatch</strong></span> types.
11559                       </p>
11560                     </td>
11561 </tr>
11562 <tr>
11563 <td>
11564                       <p><span><strong class="command">&lt;TYPE&gt;SendErr</strong></span></p>
11565                     </td>
11566 <td>
11567                       <p>
11568                         Errors in socket send operations.
11569                         This counter corresponds
11570                         to <span><strong class="command">SErr</strong></span> counter of
11571                         <span><strong class="command">BIND</strong></span> 8.
11572                       </p>
11573                     </td>
11574 </tr>
11575 <tr>
11576 <td>
11577                       <p><span><strong class="command">&lt;TYPE&gt;RecvErr</strong></span></p>
11578                     </td>
11579 <td>
11580                       <p>
11581                         Errors in socket receive operations.
11582                         This includes errors of send operations on a
11583                         connected UDP socket notified by an ICMP error
11584                         message.
11585                       </p>
11586                     </td>
11587 </tr>
11588 </tbody>
11589 </table></div>
11590 </div>
11591 <div class="sect3" lang="en">
11592 <div class="titlepage"><div><div><h4 class="title">
11593 <a name="id2604425"></a>Compatibility with <span class="emphasis"><em>BIND</em></span> 8 Counters</h4></div></div></div>
11594 <p>
11595               Most statistics counters that were available
11596               in <span><strong class="command">BIND</strong></span> 8 are also supported in
11597               <span><strong class="command">BIND</strong></span> 9 as shown in the above tables.
11598               Here are notes about other counters that do not appear
11599               in these tables.
11600             </p>
11601 <div class="variablelist"><dl>
11602 <dt><span class="term"><span><strong class="command">RFwdR,SFwdR</strong></span></span></dt>
11603 <dd><p>
11604                     These counters are not supported
11605                     because <span><strong class="command">BIND</strong></span> 9 does not adopt
11606                     the notion of <span class="emphasis"><em>forwarding</em></span>
11607                     as <span><strong class="command">BIND</strong></span> 8 did.
11608                   </p></dd>
11609 <dt><span class="term"><span><strong class="command">RAXFR</strong></span></span></dt>
11610 <dd><p>
11611                     This counter is accessible in the Incoming Queries section.
11612                   </p></dd>
11613 <dt><span class="term"><span><strong class="command">RIQ</strong></span></span></dt>
11614 <dd><p>
11615                     This counter is accessible in the Incoming Requests section.
11616                   </p></dd>
11617 <dt><span class="term"><span><strong class="command">ROpts</strong></span></span></dt>
11618 <dd><p>
11619                     This counter is not supported
11620                     because <span><strong class="command">BIND</strong></span> 9 does not care
11621                     about IP options in the first place.
11622                   </p></dd>
11623 </dl></div>
11624 </div>
11625 </div>
11626 </div>
11627 </div>
11628 <div class="navfooter">
11629 <hr>
11630 <table width="100%" summary="Navigation footer">
11631 <tr>
11632 <td width="40%" align="left">
11633 <a accesskey="p" href="Bv9ARM.ch05.html">Prev</a> </td>
11634 <td width="20%" align="center"> </td>
11635 <td width="40%" align="right"> <a accesskey="n" href="Bv9ARM.ch07.html">Next</a>
11636 </td>
11637 </tr>
11638 <tr>
11639 <td width="40%" align="left" valign="top">Chapter 5. The <acronym class="acronym">BIND</acronym> 9 Lightweight Resolver </td>
11640 <td width="20%" align="center"><a accesskey="h" href="Bv9ARM.html">Home</a></td>
11641 <td width="40%" align="right" valign="top"> Chapter 7. <acronym class="acronym">BIND</acronym> 9 Security Considerations</td>
11642 </tr>
11643 </table>
11644 </div>
11645 <p style="text-align: center;">BIND 9.9.7 (Extended Support Version)</p>
11646 </body>
11647 </html>