Bv9ARM.ch05.html revision 12351e0500dff39f56844401fd191a36bcc4a7ad
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<!--
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC")
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - Copyright (C) 2000-2003 Internet Software Consortium.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync -
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - Permission to use, copy, modify, and distribute this software for any
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - purpose with or without fee is hereby granted, provided that the above
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - copyright notice and this permission notice appear in all copies.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync -
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
a180a41bba1d50822df23fff0099e90b86638b89vboxsync - PERFORMANCE OF THIS SOFTWARE.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync-->
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<!-- $Id: Bv9ARM.ch05.html,v 1.63 2007/05/30 02:30:14 marka Exp $ -->
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<html>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<head>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<title>Chapter�5.�The BIND 9 Lightweight Resolver</title>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<meta name="generator" content="DocBook XSL Stylesheets V1.71.1">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<link rel="start" href="Bv9ARM.html" title="BIND 9 Administrator Reference Manual">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<link rel="up" href="Bv9ARM.html" title="BIND 9 Administrator Reference Manual">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<link rel="prev" href="Bv9ARM.ch04.html" title="Chapter�4.�Advanced DNS Features">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<link rel="next" href="Bv9ARM.ch06.html" title="Chapter�6.�BIND 9 Configuration Reference">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</head>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="navheader">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<table width="100%" summary="Navigation header">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<tr><th colspan="3" align="center">Chapter�5.�The <acronym class="acronym">BIND</acronym> 9 Lightweight Resolver</th></tr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<tr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<td width="20%" align="left">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<a accesskey="p" href="Bv9ARM.ch04.html">Prev</a>�</td>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<th width="60%" align="center">�</th>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<td width="20%" align="right">�<a accesskey="n" href="Bv9ARM.ch06.html">Next</a>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</td>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</tr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</table>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<hr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="chapter" lang="en">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="titlepage"><div><div><h2 class="title">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<a name="Bv9ARM.ch05"></a>Chapter�5.�The <acronym class="acronym">BIND</acronym> 9 Lightweight Resolver</h2></div></div></div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="toc">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p><b>Table of Contents</b></p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<dl>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<dt><span class="sect1"><a href="Bv9ARM.ch05.html#id2572285">The Lightweight Resolver Library</a></span></dt>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<dt><span class="sect1"><a href="Bv9ARM.ch05.html#lwresd">Running a Resolver Daemon</a></span></dt>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</dl>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="sect1" lang="en">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="titlepage"><div><div><h2 class="title" style="clear: both">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<a name="id2572285"></a>The Lightweight Resolver Library</h2></div></div></div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync Traditionally applications have been linked with a stub resolver
a180a41bba1d50822df23fff0099e90b86638b89vboxsync library that sends recursive DNS queries to a local caching name
a180a41bba1d50822df23fff0099e90b86638b89vboxsync server.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync </p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync IPv6 once introduced new complexity into the resolution process,
a180a41bba1d50822df23fff0099e90b86638b89vboxsync such as following A6 chains and DNAME records, and simultaneous
a180a41bba1d50822df23fff0099e90b86638b89vboxsync lookup of IPv4 and IPv6 addresses. Though most of the complexity was
a180a41bba1d50822df23fff0099e90b86638b89vboxsync then removed, these are hard or impossible
a180a41bba1d50822df23fff0099e90b86638b89vboxsync to implement in a traditional stub resolver.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync </p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync <acronym class="acronym">BIND</acronym> 9 therefore can also provide resolution
a180a41bba1d50822df23fff0099e90b86638b89vboxsync services to local clients
a180a41bba1d50822df23fff0099e90b86638b89vboxsync using a combination of a lightweight resolver library and a resolver
a180a41bba1d50822df23fff0099e90b86638b89vboxsync daemon process running on the local host. These communicate using
a180a41bba1d50822df23fff0099e90b86638b89vboxsync a simple UDP-based protocol, the "lightweight resolver protocol"
a180a41bba1d50822df23fff0099e90b86638b89vboxsync that is distinct from and simpler than the full DNS protocol.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync </p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="sect1" lang="en">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="titlepage"><div><div><h2 class="title" style="clear: both">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<a name="lwresd"></a>Running a Resolver Daemon</h2></div></div></div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync To use the lightweight resolver interface, the system must
a180a41bba1d50822df23fff0099e90b86638b89vboxsync run the resolver daemon <span><strong class="command">lwresd</strong></span> or a
a180a41bba1d50822df23fff0099e90b86638b89vboxsync local
a180a41bba1d50822df23fff0099e90b86638b89vboxsync name server configured with a <span><strong class="command">lwres</strong></span>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync statement.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync </p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync By default, applications using the lightweight resolver library will
a180a41bba1d50822df23fff0099e90b86638b89vboxsync make
a180a41bba1d50822df23fff0099e90b86638b89vboxsync UDP requests to the IPv4 loopback address (127.0.0.1) on port 921.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync The
a180a41bba1d50822df23fff0099e90b86638b89vboxsync address can be overridden by <span><strong class="command">lwserver</strong></span>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync lines in
a180a41bba1d50822df23fff0099e90b86638b89vboxsync <code class="filename">/etc/resolv.conf</code>.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync </p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync The daemon currently only looks in the DNS, but in the future
a180a41bba1d50822df23fff0099e90b86638b89vboxsync it may use other sources such as <code class="filename">/etc/hosts</code>,
a180a41bba1d50822df23fff0099e90b86638b89vboxsync NIS, etc.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync </p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync The <span><strong class="command">lwresd</strong></span> daemon is essentially a
a180a41bba1d50822df23fff0099e90b86638b89vboxsync caching-only name server that responds to requests using the
a180a41bba1d50822df23fff0099e90b86638b89vboxsync lightweight
a180a41bba1d50822df23fff0099e90b86638b89vboxsync resolver protocol rather than the DNS protocol. Because it needs
a180a41bba1d50822df23fff0099e90b86638b89vboxsync to run on each host, it is designed to require no or minimal
a180a41bba1d50822df23fff0099e90b86638b89vboxsync configuration.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync Unless configured otherwise, it uses the name servers listed on
a180a41bba1d50822df23fff0099e90b86638b89vboxsync <span><strong class="command">nameserver</strong></span> lines in <code class="filename">/etc/resolv.conf</code>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync as forwarders, but is also capable of doing the resolution
a180a41bba1d50822df23fff0099e90b86638b89vboxsync autonomously if
a180a41bba1d50822df23fff0099e90b86638b89vboxsync none are specified.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync </p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync The <span><strong class="command">lwresd</strong></span> daemon may also be
a180a41bba1d50822df23fff0099e90b86638b89vboxsync configured with a
a180a41bba1d50822df23fff0099e90b86638b89vboxsync <code class="filename">named.conf</code> style configuration file,
a180a41bba1d50822df23fff0099e90b86638b89vboxsync in
a180a41bba1d50822df23fff0099e90b86638b89vboxsync <code class="filename">/etc/lwresd.conf</code> by default. A name
a180a41bba1d50822df23fff0099e90b86638b89vboxsync server may also
a180a41bba1d50822df23fff0099e90b86638b89vboxsync be configured to act as a lightweight resolver daemon using the
a180a41bba1d50822df23fff0099e90b86638b89vboxsync <span><strong class="command">lwres</strong></span> statement in <code class="filename">named.conf</code>.
a180a41bba1d50822df23fff0099e90b86638b89vboxsync </p>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<div class="navfooter">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<hr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<table width="100%" summary="Navigation footer">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<tr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<td width="40%" align="left">
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<a accesskey="p" href="Bv9ARM.ch04.html">Prev</a>�</td>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<td width="20%" align="center">�</td>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<td width="40%" align="right">�<a accesskey="n" href="Bv9ARM.ch06.html">Next</a>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</td>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</tr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<tr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<td width="40%" align="left" valign="top">Chapter�4.�Advanced DNS Features�</td>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<td width="20%" align="center"><a accesskey="h" href="Bv9ARM.html">Home</a></td>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync<td width="40%" align="right" valign="top">�Chapter�6.�<acronym class="acronym">BIND</acronym> 9 Configuration Reference</td>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</tr>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</table>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</div>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</body>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync</html>
a180a41bba1d50822df23fff0099e90b86638b89vboxsync