Bv9ARM.ch05.html revision 2cd182921e1b04ccda0a56995c4cc491c882af04
199767f8919635c4928607450d9e0abb932109ceToomas Soome<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
199767f8919635c4928607450d9e0abb932109ceToomas Soome<HTML
199767f8919635c4928607450d9e0abb932109ceToomas Soome><HEAD
199767f8919635c4928607450d9e0abb932109ceToomas Soome><TITLE
199767f8919635c4928607450d9e0abb932109ceToomas Soome>The BIND 9 Lightweight Resolver</TITLE
199767f8919635c4928607450d9e0abb932109ceToomas Soome><META
199767f8919635c4928607450d9e0abb932109ceToomas SoomeNAME="GENERATOR"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeCONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK
199767f8919635c4928607450d9e0abb932109ceToomas SoomeREL="HOME"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeTITLE="BIND 9 Administrator Reference Manual"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeHREF="Bv9ARM.html"><LINK
199767f8919635c4928607450d9e0abb932109ceToomas SoomeREL="PREVIOUS"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeTITLE="Advanced DNS Features"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeHREF="Bv9ARM.ch04.html"><LINK
199767f8919635c4928607450d9e0abb932109ceToomas SoomeREL="NEXT"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeTITLE="BIND 9 Configuration Reference"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeHREF="Bv9ARM.ch06.html"></HEAD
199767f8919635c4928607450d9e0abb932109ceToomas Soome><BODY
199767f8919635c4928607450d9e0abb932109ceToomas SoomeCLASS="chapter"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeBGCOLOR="#FFFFFF"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeTEXT="#000000"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeLINK="#0000FF"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeVLINK="#840084"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeALINK="#0000FF"
199767f8919635c4928607450d9e0abb932109ceToomas Soome><DIV
199767f8919635c4928607450d9e0abb932109ceToomas SoomeCLASS="NAVHEADER"
199767f8919635c4928607450d9e0abb932109ceToomas Soome><TABLE
199767f8919635c4928607450d9e0abb932109ceToomas SoomeSUMMARY="Header navigation table"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeWIDTH="100%"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeBORDER="0"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeCELLPADDING="0"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeCELLSPACING="0"
199767f8919635c4928607450d9e0abb932109ceToomas Soome><TR
199767f8919635c4928607450d9e0abb932109ceToomas Soome><TH
199767f8919635c4928607450d9e0abb932109ceToomas SoomeCOLSPAN="3"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeALIGN="center"
199767f8919635c4928607450d9e0abb932109ceToomas Soome>BIND 9 Administrator Reference Manual</TH
199767f8919635c4928607450d9e0abb932109ceToomas Soome></TR
199767f8919635c4928607450d9e0abb932109ceToomas Soome><TR
199767f8919635c4928607450d9e0abb932109ceToomas Soome><TD
199767f8919635c4928607450d9e0abb932109ceToomas SoomeWIDTH="10%"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeALIGN="left"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeVALIGN="bottom"
199767f8919635c4928607450d9e0abb932109ceToomas Soome><A
199767f8919635c4928607450d9e0abb932109ceToomas SoomeHREF="Bv9ARM.ch04.html"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeACCESSKEY="P"
199767f8919635c4928607450d9e0abb932109ceToomas Soome>Prev</A
199767f8919635c4928607450d9e0abb932109ceToomas Soome></TD
199767f8919635c4928607450d9e0abb932109ceToomas Soome><TD
199767f8919635c4928607450d9e0abb932109ceToomas SoomeWIDTH="80%"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeALIGN="center"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeVALIGN="bottom"
199767f8919635c4928607450d9e0abb932109ceToomas Soome></TD
199767f8919635c4928607450d9e0abb932109ceToomas Soome><TD
199767f8919635c4928607450d9e0abb932109ceToomas SoomeWIDTH="10%"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeALIGN="right"
199767f8919635c4928607450d9e0abb932109ceToomas SoomeVALIGN="bottom"
199767f8919635c4928607450d9e0abb932109ceToomas Soome><A
HREF="Bv9ARM.ch06.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><DIV
CLASS="chapter"
><H1
><A
NAME="ch05"
></A
>Chapter 5. The <ACRONYM
CLASS="acronym"
>BIND</ACRONYM
> 9 Lightweight Resolver</H1
><DIV
CLASS="TOC"
><DL
><DT
><B
>Table of Contents</B
></DT
><DT
>5.1. <A
HREF="Bv9ARM.ch05.html#AEN1034"
>The Lightweight Resolver Library</A
></DT
><DT
>5.2. <A
HREF="Bv9ARM.ch05.html#lwresd"
>Running a Resolver Daemon</A
></DT
></DL
></DIV
><DIV
CLASS="sect1"
><H1
CLASS="sect1"
><A
NAME="AEN1034"
>5.1. The Lightweight Resolver Library</A
></H1
><P
>Traditionally applications have been linked with a stub resolver
library that sends recursive DNS queries to a local caching name
server.</P
><P
>IPv6 once introduced new complexity into the resolution process,
such as following A6 chains and DNAME records, and simultaneous
lookup of IPv4 and IPv6 addresses. Though most of the complexity was
then removed, these are hard or impossible
to implement in a traditional stub resolver.</P
><P
>Instead, <ACRONYM
CLASS="acronym"
>BIND</ACRONYM
> 9 provides resolution services to local clients
using a combination of a lightweight resolver library and a resolver
daemon process running on the local host. These communicate using
a simple UDP-based protocol, the "lightweight resolver protocol"
that is distinct from and simpler than the full DNS protocol.</P
></DIV
><DIV
CLASS="sect1"
><H1
CLASS="sect1"
><A
NAME="lwresd"
>5.2. Running a Resolver Daemon</A
></H1
><P
>To use the lightweight resolver interface, the system must
run the resolver daemon <B
CLASS="command"
>lwresd</B
> or a local
name server configured with a <B
CLASS="command"
>lwres</B
> statement.</P
><P
>By default, applications using the lightweight resolver library will make
UDP requests to the IPv4 loopback address (127.0.0.1) on port 921. The
address can be overridden by <B
CLASS="command"
>lwserver</B
> lines in
<TT
CLASS="filename"
>/etc/resolv.conf</TT
>.</P
><P
>The daemon currently only looks in the DNS, but in the future
it may use other sources such as <TT
CLASS="filename"
>/etc/hosts</TT
>,
NIS, etc.</P
><P
>The <B
CLASS="command"
>lwresd</B
> daemon is essentially a
caching-only name server that responds to requests using the lightweight
resolver protocol rather than the DNS protocol. Because it needs
to run on each host, it is designed to require no or minimal configuration.
Unless configured otherwise, it uses the name servers listed on
<B
CLASS="command"
>nameserver</B
> lines in <TT
CLASS="filename"
>/etc/resolv.conf</TT
>
as forwarders, but is also capable of doing the resolution autonomously if
none are specified.</P
><P
>The <B
CLASS="command"
>lwresd</B
> daemon may also be configured with a
<TT
CLASS="filename"
>named.conf</TT
> style configuration file, in
<TT
CLASS="filename"
>/etc/lwresd.conf</TT
> by default. A name server may also
be configured to act as a lightweight resolver daemon using the
<B
CLASS="command"
>lwres</B
> statement in <TT
CLASS="filename"
>named.conf</TT
>.</P
></DIV
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
SUMMARY="Footer navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="Bv9ARM.ch04.html"
ACCESSKEY="P"
>Prev</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="Bv9ARM.html"
ACCESSKEY="H"
>Home</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="Bv9ARM.ch06.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>Advanced DNS Features</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
>&nbsp;</TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><ACRONYM
CLASS="acronym"
>BIND</ACRONYM
> 9 Configuration Reference</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>