One issue I ran into on one of my Ubuntu servers was that each time i put my nameserver into the /etc/resolv.conf it was being reset back to a blank page after a reboot. Well there is tons of information out there about if your using DHCP then you need to go into the dhcp config files and setup the nameserver in there. One problem, I was not using the DHCP. Most of us running Linux on a server use the static IP option so this nullifies the instruction sets Iwas finding on the net.

So here I thought I would pass along this quick little summary. The best way for you to get around this is to hard code you nameserver’s into your interface file for your ethernet card like below. For Ubuntu you can find this by going to /etc/network/interfaces and edit this file with nano or VIM or whichever you like.

As you can see on the last line using dns-nameservers with an ip is the same as using nameservers in your resolv.conf file. You can also add multiple ip’s by separating them with a space. If you have any questions or comments, feel free to drop me a line.

Advertisements