After my upgrade to 12.10, DNS resolution seems to fail for both local and external addresses. I can successfully ping local and external IP addresses (google.com, at least), but pinging DNS names immediately returns ping: unknown host <hostname>
. Connection Information seems to list the correct DNS servers (which I can ping successfully), and changing to Google Public DNS produces similar results. What should I fuss with to try to fix this?
Add a comment
|
3 Answers
Change 127.0.0.1 to 127.0.1.1 in /etc/resolv.conf
-
It looks like that worked. I was under the impression resolv.conf is generated automatically. This edit isn't going to get wiped out some day, is it?– fourwoodOct 19, 2012 at 21:13
-
-
-
-
If you have resolvconf installed then you should not edit /etc/resolv.conf, and if you do edit /etc/resolv.conf your edits will get overwritten. But if you have resolvconf installed then you don't have the problem in the first place, because NetworkManager registers the correct address, 127.0.1.1, with resolvconf which writes it into resolv.conf.– jdthoodNov 1, 2012 at 13:37
In a terminal, run
sudo apt-get install resolvconf # in case it got removed
sudo dpkg-reconfigure resolvconf # to restore the symlink at /etc/resolv.conf
then reboot.