Name Servers UNIX Name Service — BIND

options ndots • Specifies the number of dots . an argument must have in it so that the resolver will look for it before applying the search list BIND 4.9.3 and later. options debug • Turns on debugging output in the resolver BIND 4.9.3 and later. ; and • Specify comment lines in the resolver configuration file; comments with have been allowed since BIND 4.9.3. The default search algorithm was also changed with the release of BIND 4.9.3; the domain directive specifies the default search list. The default search list originally included the default domain and each of its parent domains with two or more labels. For each relative host name host name without a trailing dot, first a full domain is appended, then its parent domain, then the next parent domain, and so on until the last two labels. The single last label is never appended. The host name is looked up as is after the search list is applied, and then only if the host name contains at least one dot. A search is terminated as soon as a positive response to the resolver query has been obtained. With BIND 4.9.3, the default search list includes only the default domain; in addition, the search list is applied after the host name is tried as is. Obviously, the search directive should be used for more detailed searching.

16.2.3 Name Servers

Several BIND configuration options exist for the name server software. The basic ones are discussed in the following paragraphs. Primary name server — A primary name server is the authoritative source for all information about a specific domain, i.e., zone. It loads the domain information from locally maintained data files that are built by the network administrator. The zone file contains the most accurate information about a piece of the domain hierarchy over which this server has authority. This is the master server for its domain, because it can answer any related query with full authority. Secondary name server — A secondary name server transfers a complete set of domain information from the primary name server and stores it as local files. This transfer is called a zone file transfer. This is also the master server for its domain; by strictly following a primary name server and keeping a complete copy of all domain information, the secondary server can answer queries about that domain with authority. Caching−only name server — Name server software is running on the system, but no database is kept locally. It learns the answer to every name server query from some remote server and caches it locally. This means that a caching−only server only looks for external help the first time; after that it is ready to support with nonauthoritative answers. This self−learning procedure leads relatively quickly to the large local cached database. All name servers use cached information in this manner, but a caching−only server depends on this technique for all of its name server information. Forwarder — The forwarder is a special type of caching−only server. A separate name server to resolve off−site host names can be configured to limit the off−site DNS traffic. In that case, all resolvers forward queries related to off−site hosts to this particular server, which then responds from its cached database, or continues alone to query other off−site servers. Soon a respectable off−site 380 16.2.3.1 The named Daemon Name server software consists of the name server daemon, named, and a number of appropriate configuration files. A brief description of named follows: named is the Internet domain name server. Resolver libraries use it to provide access to the Internet distributed naming database Requests for Comments RFC 1034 and RFC 1035 are available for more details. The default configuration file is etcnamed.boot, i.e., etcnamed.conf. If the daemon is started with no arguments, named reads the default configuration file for any initial data; afterward, it continues to listen for queries on a privileged port. The usual name for the program is named, though Sun systems Solaris 2.x and SunOS 4.1.x use the name in.named which stands for Internet name daemon. We will discuss the name daemon named by primarily addressing the Solaris 2.x platform. This is a sufficiently general approach, and the possible differences among UNIX flavors are marginal. The Solaris command to start the daemon is: usretcin.named [ −d level ] [ −p port ] [[−b] bootfile ] where −d level Print debugging information; level is a number indicating the level of messages printed −p port Use port as the port number, rather than the standard port number −b bootfile Use bootfile as the configuration file instead of etcnamed.boot The main issue related to the named daemon is its configuration, more specifically the etcnamed.boot file this is the old name for the configuration file. We will talk about the named configuration later. Besides the configuration file, other named −related files of interest are: etcnamed.pid The process ID vartmpnamed.run Debug output vartmpnamed_dump.db Dump of the name servers database The named daemon is started during the system booting only if the system is configured as a name server of any kind, i.e., it contains the basic name server configuration file etcnamed.boot. The corresponding rc script sequence is: 381 in.named; echo −n named fi Once the name server daemon is started, it writes its PID in the etcnamed.pid file. Any later change in the name server configuration requires the daemon to be recycled. The easiest way to do that is: kill −HUP cat etcnamed.pid The named daemon logs errors into the system log file for SunOS Solaris the usradmmessages file, so this file could be checked when any modification is made. Other log files can be used for debugging purposes these were listed earlier. Once named is running properly, other utilities are available to make sure it is working correctly.

16.3 Configuring named

Configuring the named daemon is a complex task. The complete set of named configuration files contains: etcnamed.boot etcnamed.conf This is the master DNS server configuration file. For a long time its name was named.boot, lately changed into the more appropriate name named.conf since version 8. The file is crucial for named daemon configuration — practically everything is specified within this file. First, it specifies the name server type; then it sets named parameters and points to the sources of domain database information used by the server. The sources could be strictly local files for the primary server, or transferred data from remote servers. Regardless of data origin, the names and locations of files where the data are kept are specified here. named.hosts The zone file that maps host names to IP addresses. named.in−addr The zone file for the reverse domain that maps IP addresses to host names. named.local The file used to locally resolve the loopback address. The file that points to the root domain servers. 382