Difference between revisions of "Add DNS server via resolvconf for Ubuntu Server"

From banana_wiki
Jump to: navigation, search
 
Line 10: Line 10:
 
Then once settings are in place run:
 
Then once settings are in place run:
  
<tt>sudo resolvconf -u</tt>
+
<pre>sudo resolvconf -u</pre>

Latest revision as of 00:32, 25 November 2014

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