Solaris Naming Administration Guide

DNS and Internet Access

The nsswitch.conf file also controls DNS forwarding for clients as described in the following subsections. DNS forwarding grants Internet access to clients.


Note -

The NIS+ client must have a properly configured /etc/resolv.conf file (as described in "DNS Clients and the Resolver").


See the switch file chapter of Solaris Naming Setup and Configuration Guide for step-by-step instructions on enabling DNS forwarding for NIS+ and NIS clients.

DNS Forwarding for NIS+ Clients

NIS+ clients do not have implicit DNS forwarding capabilities like NIS clients do. Instead, they take advantage of the switch. To provide DNS forwarding capabilities to an NIS+ client, change its hosts entry to:


hosts: nisplus dns [NOTFOUND=return] files

DNS Forwarding for NIS Clients

DNS forwarding is inherent in the NIS name service. The proper format for the hosts line in a NIS-primary switch file to enable DNS forwarding is:


hosts: nis [NOTFOUND=return] files

Caution - Caution -

If an NIS client is using the DNS forwarding capability of a NIS-compatible NIS+ server, its nsswitch.conf file should not have hosts: nis dns files as the syntax for the hosts file. This is because DNS forwarding automatically forwards host requests to DNS and this syntax would cause the NIS+ server to forward unsuccessful requests to the DNS servers twice, which would reduce performance. To take best advantage of DNS forwarding, use the default syntax for the nsswitch.nis file.