Add DNS server via resolvconf for Ubuntu Server

From banana_wiki
Revision as of 00:31, 25 November 2014 by Bananafish (talk | contribs)
Jump to: navigation, search

For some reason Ubuntu no longer respects /etc/resolv.conf and requires resolvconf to make changes to DNS lookups. This is usually needed after setting a static IP on Ubuntu Server.

cd /etc/resolvconf/resolv.conf.d
sudo cp -p head head.orig
sudo vi head

In this file we need to add something like the following:

nameserver x.x.x.x
search domain.local

Then once settings are in place run:

sudo resolvconf -u