When I use DNS servers other than my router's IP address, Ubuntu or any other application (web browser) fails to resolve host names.
I have added Google's DNS servers (8.8.8.8 and 8.8.4.4) using Ubuntu's default network manager UI.
When I add my router's IP address in (8.8.8.8, 8.8.4.4, and 192.168.15.1), DNS resolution starts working.
Here is my related configuration:
resolv.conf:
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 127.0.0.1
NetworkManager.conf:
[main]
plugins=ifupdown,keyfile
dns=dnsmasq
no-auto-default=<some mac address>,
[ifupdown]
managed=false
/etc/network/interfaces:
auto lo
iface lo inet loopback
I've tried different solutions, like disabling dnsmasq from networkmanager.conf, but nothing worked.
Here are host and dig results:
host www.google.com 8.8.8.8 - times out.
host www.google.com 192.168.15.1 - works immediatly.
dig @8.8.8.8 www.google.com - times out.
dig @192.168.15.1 www.google.com - works immediatly.
However, I am able to ping to 8.8.8.8 successfully, meaning the server is reachable at least.
Is it possible that my router or ISP is rejecting DNS requests made to servers other than the ones set by my ISP in my router?