49

I am running Ubuntu 14.04 LTS on my Dell M3800.

I am having problems connecting to the Internet.

I getDNS_PROBE_FINISHED_BAD_CONFIG in my browser when trying to navigate to any site, but I am able to navigate to any site by using its IP.

So, for example, I am able to navigate to google.com by using http://173.194.121.16. So I think somewhere my DNS settings got messed up.

Any pointer on resolving this issue is appreciated. Please, let me know if you need any more information.

Amrish
  • 1,331
  • 1
  • 10
  • 14

3 Answers3

69

So I figured out what the problem was. When I ran the following command sudo resolvconf -u I got this error:

/etc/resolvconf/update.d/libc: Warning: /etc/resolv.conf is not a symbolic link to /run/resolvconf/resolv.conf`

I solved this error by deleting /etc/resolv.conf and recreating the symbolic link. You can do that using the following commands:

sudo rm /etc/resolv.conf
sudo ln -s /run/resolvconf/resolv.conf /etc/resolv.conf
sudo resolvconf -u

This resolved the DNS error I was getting.

for Ubuntu 20.04 and above, just

sudo ln -s /run/systemd/resolve/resolv.conf /etc/resolv.conf
M.A.K. Ripon
  • 3,139
Amrish
  • 1,331
  • 1
  • 10
  • 14
21
sudo dpkg-reconfigure resolvconf

Say yes to "prepare /etc/resolve.conf for dynamic updates?"

sudo reboot
Gayan Weerakutti
  • 3,770
  • 26
  • 38
0

I had this problem when using NordVPN and using openvpn via terminal. I resolved this problem by importing VPN configuration file to Ubuntu Network UI. You can go to Settings -> Network. There will be VPN section, press add and then import file. Choose one of the downloaded .ovpn files from NordVPN. Then when you try to connect it seems to automatically fix DNS issue for some reason. :)

Actually that's what I expected because sometimes UI solutions are more stable than running Terminal commands.

Daniel
  • 758
  • 6
  • 16