1 .\" Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
3 .\" Permission to use, copy, modify, and distribute this software for any
4 .\" purpose with or without fee is hereby granted, provided that the above
5 .\" copyright notice and this permission notice appear in all copies.
7 .\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
8 .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
9 .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR
10 .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
11 .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
12 .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
13 .\" OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15 .\" Copyright (c) 1986 The Regents of the University of California.
16 .\" All rights reserved.
18 .\" Redistribution and use in source and binary forms are permitted
19 .\" provided that the above copyright notice and this paragraph are
20 .\" duplicated in all such forms and that any documentation,
21 .\" advertising materials, and other materials related to such
22 .\" distribution and use acknowledge that the software was developed
23 .\" by the University of California, Berkeley. The name of the
24 .\" University may not be used to endorse or promote products derived
25 .\" from this software without specific prior written permission.
26 .\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
27 .\" IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
28 .\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
30 .\" @(#)resolver.5 5.9 (Berkeley) 12/14/89
31 .\" Id: resolver.man5,v 1.2 2009/01/21 00:12:34 each Exp
38 .Nd resolver configuration file
44 is a set of routines in the C library
46 that provide access to the Internet Domain Name System.
49 configuration file contains information that is read
52 routines the first time they are invoked by a process.
53 The file is designed to be human readable and contains a list of
54 keywords with values that provide various types of
58 On a normally configured system, this file should not be necessary.
59 The only name server to be queried will be on the local machine,
60 the domain name is determined from the host name,
61 and the domain search path is constructed from the domain name.
63 The different configuration directives are:
64 .Bl -tag -width "nameser"
66 Internet address (in dot notation) of a name server that the
72 name servers may be listed, one per keyword.
73 If there are multiple servers, the
75 library queries them in the order listed.
78 entries are present, the default is to use the name server on the local machine.
79 (The algorithm used is to try a name server, and if the query times out,
80 try the next, until out of name servers,
81 then repeat trying all the name servers
82 until a maximum number of retries are made).
85 Most queries for names within this domain can use short names
86 relative to the local domain.
89 entry is present, the domain is determined from the local host name returned by
91 the domain part is taken to be everything after the first
93 Finally, if the host name does not contain a domain part, the root
96 Search list for host-name lookup.
97 The search list is normally determined from the local domain name;
98 by default, it contains only the local domain name.
99 This may be changed by listing the desired domain search path
102 keyword with spaces or tabs separating the names.
105 queries will be attempted using each component
106 of the search path in turn until a match is found.
107 Note that this process may be slow and will generate a lot of network
108 traffic if the servers for the listed domains are not local,
109 and that queries will time out if no server is available
110 for one of the domains.
112 The search list is currently limited to six domains
113 with a total of 256 characters.
115 Allows addresses returned by gethostbyname to be sorted.
118 is specified by IP address netmask pairs. The netmask is
119 optional and defaults to the natural netmask of the net. The IP address
120 and optional network pairs are separated by slashes. Up to 10 pairs may
121 be specified. For example:
122 .Bd -literal -offset indent
123 sortlist 130.155.160.0/255.255.240.0 130.155.0.0
126 Allows certain internal
128 variables to be modified.
130 .D1 Li options Ar option ...
133 is one of the following:
134 .Bl -tag -width "ndots:n "
140 .It Li ndots: Ns Ar n
141 sets a threshold for the number of dots which
142 must appear in a name given to
147 .Em initial absolute query
148 will be made. The default for
152 meaning that if there are
154 dots in a name, the name will be tried first as an absolute name before any
156 elements are appended to it.
157 .It Li timeout: Ns Ar n
158 sets the amount of time the resolver will wait for a response from a remote
159 name server before retrying the query via a different name server. Measured in
160 seconds, the default is
164 .It Li attempts: Ns Ar n
165 sets the number of times the resolver will send a query to its name servers
166 before giving up and returning an error to the calling application. The
176 which causes round robin selection of nameservers from among those listed.
177 This has the effect of spreading the query load among all listed servers,
178 rather than having all clients try the first listed server first every time.
179 .It Li no-check-names
184 which disables the modern BIND checking of incoming host names and mail names
185 for invalid characters such as underscore (_), non-ASCII, or control characters.
191 This has the effect of trying a AAAA query before an A query inside the
193 function, and of mapping IPv4 responses in IPv6 ``tunnelled form'' if no
194 AAAA records are found but an A record set exists.
202 to not attempt to resolve a unqualified name as if it were a top level
204 This option can cause problems if the site has "localhost" as a TLD rather
205 than having localhost on one or more elements of the search list.
206 This option has no effect if neither
218 keywords are mutually exclusive.
219 If more than one instance of these keywords is present,
220 the last instance wins.
224 keyword of a system's
227 overridden on a per-process basis by setting the environment variable
229 to a space-separated list of search domains.
233 keyword of a system's
235 file can be amended on a per-process basis by setting the environment variable
236 .Dq Ev RES_OPTIONS to a space-separated list of
238 options as explained above under
241 The keyword and value must appear on a single line, and the keyword
244 must start the line. The value follows the keyword, separated by white space.
249 .Xr gethostbyname 3 ,
253 .Dq Name Server Operations Guide for Sy BIND