Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Reference > L


BIND 9.3
HP-UX 11i Version 3: February 2007

Technical documentation

» Feedback
Content starts here

 » Table of Contents

 » Index


lwresd — lightweight resolver daemon


lwresd [-fgs] [-C config-file] [-d debuglevel] [-i pid-file] [-n ncpus] [-P query-port] [-p port] [-t directory] [-u user-id]


The lwresd daemon provides name lookup services for clients that use the BIND 9 lightweight resolver library. It is essentially a stripped-down, caching-only name server that answers queries using the BIND 9 lightweight resolver protocol rather than the DNS protocol.

lwresd listens for resolver queries on a UDP port on the IPv4 loopback interface, This means that lwresd can only be used by processes running on the local machine. By default, UDP port number 921 is used for lightweight resolver requests and responses.

Incoming lightweight resolver requests are decoded by lwresd which then resolves them using the DNS protocol. When the DNS lookup completes, lwresd encodes the answers from the name servers in the lightweight resolver format and returns them to the client that made the original request.

If the /etc/resolv.conf configuration file contains any nameserver entries, lwresd sends recursive DNS queries to those servers. This is similar to the use of forwarders in a caching name server. If no nameserver entries are present, or if forwarding fails, lwresd resolves the queries autonomously starting at the root name servers, using a compiled-in list of root-server hints.


-C config-file

Use config-file as the configuration file. The default is /etc/resolv.conf.

-d debuglevel

Set the debug level to debuglevel. Debugging traces from lwresd become more verbose as the debug level increases.


Run lwresd in the foreground.


Run lwresd in the foreground and force all logging to standard error.

-i pid-file

Write the daemon's process ID to pid-file. The default is /var/run/lwresd.pid.

-n ncpus

Create ncpus worker threads to take advantage of multiple CPUs. By default, lwresd tries to determine the number of CPUs present and creates one thread per CPU. If it cannot determine the number of CPUs, it creates a single worker thread.

-P query-port

Send DNS lookups to port number query-port when querying name servers. This provides a way of testing the lightweight resolver daemon with a name server that listens for queries on a nonstandard port number.

-p port

Listen for lightweight resolver queries on the loopback interface using UDP port number port. The default is port 921.


Write memory usage statistics to standard output on exit. This option is only of interest to BIND 9 developers and may be removed or changed in a future release.

-t directory

Change root to directory immediately after reading the configuration file (see chroot(2)).

-u user-id

Run as user-id, which is a user name or numeric ID that must be present in the password file. lwresd changes its user-id after it has carried out any privileged operations, such as writing the process-ID file or binding a socket to a privileged port (typically any port less than 1024).


lwresd is a daemon for lightweight resolvers, not a lightweight daemon for resolvers.


lwresd was developed by the Internet Systems Consortium (ISC).



Default resolver configuration file


Default process-id file


named(1M), chroot(2).

HP-UX IP Address and Client Management Administrator's Guide, available online at http://docs.hp.com.

BIND 9 Administrator Reference Manual, available from the Internet Systems Consortium at http://www.isc.org/sw/bind/arm93.

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1983-2007 Hewlett-Packard Development Company, L.P.