Log et al – Peter Curd

An irreverent peek into the inner rumblings of Peter Curd



DNS in Linux

By pcurd

I have a world of problems with DNS in Linux. My Ubuntu box is sat on a Windows 2000 domain and usually holds it’s own. It’s not a member of Active Directory nor does it import great knowledge from Active Directory – it is an island of peace amongst the Kerberos hoards.

Most recent problem – after an unscheduled, shall we say ungraceful, shutdown of the box it appeared to have dropped off the network. After a lot of faffing I found that the DNS servers were not specified anywhere, the machine became static IP from DHCP assigned between the last reboots so evidently I didn’t set it up correctly the first time. After trying several solutions this helped:



In order to assign a static nameserver, you must edit the file /etc/resolvconf/resolv.conf.d/base, and add you “nameserver x.x.x.x” line there. This file is automatically included at the start of the /etc/resolv.conf file that resolvconf generates.

To add a search domain I similarly added “search xxx.com” to the same file.

– Update

I have recently installed Ubuntu 6.10 (I know, I’m still about 2 releases behind) and I didn’t have this problem.  Good work team Ubuntu!

Leave a comment