DNS Lookup   «Prev  Next»
Lesson 6 Name server configuration
ObjectiveDefine the Elements of the Name Server Configuration File.

Define Elements of the Name Server Configuration File

The name server configuration file (/etc/named.boot) is a simple text file in which comment lines are indicated with a semicolon (;). Each line of the file addresses some aspect of name server configuration. The lines have the following format:

Directive Arguments

The code below is a typical example of an /etc/named.boot file.
Database diagram of the pet store schema
  1. The directory directive establishes an initial path for later file references, to make the file easier to read. In our example, all future file references are relative to the path /var/named
  2. The cache directive primes the cache.
  3. The arguments of the cache directive are the origin domain for the cache file, followed by the name of the file. In our example, the origin for the cache file is the root domain “.”, and the cache file name is named.ca (actually, /var/named/named.ca, thanks to the directory directive).
  4. The primary directive declares the server as an authoritative server for a particular zone.
  5. The arguments of the primary directive are the origin of the zone and the name of the zone file. In our example, our server is primary (authoritative) for corporation.com, with zone file /var/named/corp.zone, and for the reverse zone 12.143.196.in-addr.arpa, with zone file /var/named/rev.zone.
  6. The secondary directive declares the server as a secondary server for a particular zone.
  7. The arguments of the secondary directive are the origin of the zone, the IP address of the zone's primary server, and the file name where the zone file is to be stored. In this example, our server is a secondary server for company.com, the primary server is located at 196.144.12.100, and the zone file is named /var/named/company.zone.

Name Server Configuration File Example
Earlier, we pointed out that an @ sign in a zone file is replaced by the server with the appropriate zone. The information to replace the @ sign comes from the named.boot file.
Notice that no special configuration is necessary to create a caching-only server. Simply specify no primary or secondary zones (except loopback), and you will get a caching server.