Network Configuration Files

As previously stated, five network configuration files can be modified to make changes to basic network interaction of your system:

/etc/hosts—A listing of addresses, hostnames, and aliases

/etc/services—Network service and port connections

/etc/nsswitch.conf—Linux network information service configuration

/etc/resolv.confDomain Name Service (DNS) domain (search) settings

/etc/host.conf—Network information search order (by default, /etc/hosts and then DNS)

After these files are modified, the changes are active. As with most configuration files, you can add comments with a hash mark (#) preceding the comment. All these files have man pages, where you can find more information.

Adding Hosts to /etc/hosts

Get Ubuntu Unleashed 2013 Edition: Covering 12.10 and 13.04, Eighth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.