I have been trying to change my dns to 8.8.8.8
8.8.4.4
but don't seem to be able to do it.
In /etc/resolv.conf
I have
# 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
In /etc/resolvconf/resolv.conf.d/base
I added
nameserver 8.8.8.8
nameserver 8.8.4.4
and reloaded with sudo resolvconf -u
but nothing changes in /etc/resolv.conf
If I misspell something in /etc/resolvconf/resolv.conf.d/base
for example adding ameserver 8.8.8.8
and reloading cat /etc/resolv.conf
now shows.
# 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
ameserver 8.8.8.8
What should I be doing to change the dns and how can I check if it has worked?
/etc/resolv.conf
contains your dns server but it wasn't changing when I went through the usual methods. – Qwertie Jun 04 '17 at 15:06systemd-resolved is a service that provides DNS name resolution to local services and applications and it can be configured with Netplan, the default network management tool on Ubuntu 18.04 To check status:
– David May 10 '20 at 06:15systemd-resolve --status | grep 'DNS Servers' -A2
https://linuxize.com/post/how-to-set-dns-nameservers-on-ubuntu-18-04/