2
I know there is an easy fix to the problem by adding
nameserver 8.8.8.8
to /etc/resolve.conf but this is merely a hack and not a proper trouble shoot of the problem that caused the problem. If I am not wrong having the 'default'(or what do you call it ?) nameserver 127.0.0.53 should be enough on a fairly new Linux system (Ubuntu 16.04). I have gone through other related questions here and tried all those but to no avail. Some of the things I tried:
- Connecting through different NIC ( wlan0, Eth0 )
- configuring static IP (with google's DNS ) as well as dynamic IP ( with the default gateway [192.168.43.1] as the DNS.
But all without any success. I had some boot issues with the hard drive (my hard drive became unbootable for sometime because apparently there was some issue with bootloader which I fixed later with boot-repair).
In short, I can't ping google.com if there is nameserver 127.0.0.53 . But I can ping if I add nameserver 8.8.8.8
If anybody can help me to right direction that would be great. Thanks.
Update:
If it helps, I actually have dual boot system with Lubuntu 18.10 as well and it doesn't have the problem. the /etc/resolve.conf file has nameserver 127.0.0.53 .
3127.0.0.0/8 is all your PC. Why do you think a DNS service should be running on your PC? – Daniel B – 2019-02-15T20:17:25.720
1If you want to avoid 'hacking' things, your DNS servers should be coming from DHCP. Check your DHCP logs.
cat /var/lib/dhcp/dhclient.<name of interface>.leases
. What does the last entry say? – Andy – 2019-02-15T21:03:19.807@Daniel, did you understand what the question is ? – Just Khaithang – 2019-02-15T21:03:43.860
1@JustKhaithang you shouldn't have 127...* as the IP address of your DNS server. It doesn't make sense. Your machine cannot be its own DNS server. It's a valid question. – Andy – 2019-02-15T21:05:29.430
1@Andy, I face the problem with Ubuntu 16.04 only and not with the other OS- having the same connection and same network settings. The nameserver 127.0.0.53 is not doing it's job somehow. – Just Khaithang – 2019-02-15T21:10:16.477
@Andy it's the local nameserver used by systemd-resolve. the Systemd-resolves write that on the /etc/resolve.conf file. – Just Khaithang – 2019-02-15T21:12:22.843
1
See https://unix.stackexchange.com/questions/328131/ All this means is that you need to look in another place for your real DNS settings.
– Andy – 2019-02-15T21:13:42.957@Andy Some of the those commands doesn't seem to work on mine but nevertheless I think I fairly had an idea on how to look or where to look. Thanks for the link. – Just Khaithang – 2019-02-15T21:44:37.510