Hi guys,
From recently,
something happens with my DNS and it doesn't work unless I do these steps:
Disable the systemd-resolved service.
sudo systemctl disable systemd-resolved.service
Stop the Service
sudo systemctl stop systemd-resolved.service
Remove the Configuration file manually
sudo rm /etc/resolv.conf
Now, Create the file again.
sudo nano /etc/resolv.conf
Enter the Below Lines
nameserver 8.8.8.8
Press CTRL+O to save the File, Then CTRL+X to Close it
Now, Enable the Service
sudo systemctl enable systemd-resolved.service
Start the Service back.
sudo systemctl start systemd-resolved.service
When I do those steps, it works but as soon as the computer logs off or gets restarted, the Googles nameservers 8.8.8.8 get removed and some other gets added which doesn't work.
Why is this happening?
What can I do to fix this? I don't want to do these steps everytime I have to use internet.
Can I fix this without using the Googles DNS?
Hopefully.. someone will be able to help with this odd issue.
Oh and before doing the steps above, I tried pinging the Google.com which doesn't work and when pinging 8.8.8.8 it works. So the internet works but the DNS doesn't resolve unless I use googles DNS server.