Why would in resolv.conf cause problems in DNS resolution?

1: Add dns-nameservers and dns-search options to /etc/network/interfaces.

auto eth1
iface eth1 inet static
    dns-search m2osw.com

2: Remove all dns- options from files in /etc/resolvconf/resolv.conf.d/. That resolv.conf includes nameserver options after nameserver indicates that such cruft is present. If /etc/resolvconf/resolv.conf.d/tail is a symbolic link, make it a symbolic link to /dev/null.

3: Downup eth1.

sudo ifdown eth1
sudo ifup eth1

4: Look in /etc/resolv.conf. Is nameserver still there and are replies to DNS queries still delayed? If so then figure out where the nameserver line is coming from. Something is registering the listen address without starting a local nameserver at (i) One possibility is the bind9 package. If you aren't running a local BIND nameserver then purge the bind9 package (sudo apt-get purge bind9). If you are running a BIND nameserver that doesn't provide general Internet name service then edit /etc/default/bind9 and set RESOLVCONF=no, then restart the nameserver. See: https://bugs.launchpad.net/ubuntu/+source/bind9/+bug/933723 (ii) Another possibility is that you have remnants of dnsmasq or similar package on the system. Purge that package. Also purge network-manager since you aren't using it.

5: Reboot and see if things have improved, then report back here.

Using a dns server with a loopback address (e.g. causes problems:

All other dns server with a lower priority are ignored by resolvconf.

The priority of dns servers is defined by the network interfaces with which the dns-server is defined.

See /etc/resolvconf/interface-order and man 5 interface-order.

Luckily there is an environment variable to change this behaviour:


See man 8 resolvconf

If put


in /etc/default/resolvconf and restart the resolvconf service all other dns server will show up in /etc/resolv.conf.