NIS Client Networking  «Prev  Next»

Functions of nsswitch Elements

Below is a list of nsswitch elements and their definitions.
  1. map: Names the type of information held in a particular NIS database
  2. dns: Tells Linux to check a distributed database other than NIS.
  3. [notfound=return]: Tells Linux to stop searching and return an error if the last search fails on a functioning service.
  4. files: Causes Linux to check local information sources like /etc/hosts

Identifying other computers (hosts and DNS)

Each time you use a name to identify a computer, as when browsing the Web or using an e-mail address, the computer name must be translated into an IP address. To resolve names to IP addresses, Fedora and RHEL go through a search order, based on the contents of three files in the /etc directory:
  1. resolv.conf,
  2. nsswitch.conf, and
  3. host.conf
By default, it checks:
  1. Hostnames you add yourself (which end up in the /etc/hosts file).
  2. Hosts available via NIS, if an NIS server is configured
  3. Hostnames available via DNS.

You can use the Network Configuration window to add:
  1. Hostnames and IP addresses. You might do this to identify hosts on your LAN that are not configured on a DNS server.
  2. DNS search path. By adding domain names to a search path (such as linuxtoys.net), you can browse to a site by its hostname (such as jukebox), and looking for (such as jukebox.linuxtoys.net).
  3. DNS name servers. A DNS server can resolve addresses for the domains it serves and contact other DNS servers to get addresses for all other DNS domains.

Note: If you are configuring a DNS server, you can use that server to centrally store names and IP addresses for your LAN. This saves you the trouble of updating the /etc/hosts file of every computer every time you add or change a computer on your LAN.