Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

The Network Manager on KDE gets DNS configuration from DHCP and sets it automatically, but I would like to use the Google Public DNS. If I overwrite /etc/resolv.conf with nameserver 8.8.8.8 it still resolves names with the old DNS (probably cached in memory) and, of course, even if it worked, it would be annoying having to do that every time I connect to a network.

I've noticed the Network Manager lets you specify a fixed DNS with the rest being taken from DHCP, but that's on a per network basis, and I would like to set it once for whichever network I connect to (if you're on the go with a laptop that becomes an issue).

share|improve this question

1 Answer 1

up vote 1 down vote accepted

This entry explains static DNS setup which is done on per-interface basis.

Shortly: open or create the configuration file /etc/dhclient-IFACE.conf (IFACE would be eth0 for wired and wlan0 for wireless connection) and append an prepend domain-name-servers NAME.SERVER.IP.ADDR; line for each of Google nameservers.

share|improve this answer
    
Awesome, thanks! if you leave out the -IFACE, it apparently works for any interface. –  obvio171 Feb 2 '10 at 4:24

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.