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:
- nsswitch.conf, and
By default, it checks:
- Hostnames you add yourself (which end up in the /etc/hosts file).
- Hosts available via NIS, if an NIS server is configured
- Hostnames available via DNS.
You can use the Network Configuration window to add:
- Hostnames and IP addresses. You might do this to identify hosts on your LAN that are not configured on a DNS server.
- 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).
- 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.
: 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.