How To Edit Linux DNS Configuration Files

Edit /etc/resolv.conf using a text editor such as nano, vi or gedit:

nano /etc/resolv.conf

Or, for Ubuntu:

sudo nano /etc/resolv.conf

Add namesevers as necessary:

nameserver <ip address>
nameserver <ip address>
nameserver <ip address>

Save and close the config file.

See also Change Ubuntu IP Address from DHCP to Static

Leave a Reply

Your email address will not be published.