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