I just upgraded my Ubuntu 22.04 boxes to 23.10 and then to 24.04.
They stopped resolving DNS queries.
They are using systemd-resolved and resolvconf.
I just upgraded my Ubuntu 22.04 boxes to 23.10 and then to 24.04.
They stopped resolving DNS queries.
They are using systemd-resolved and resolvconf.
If your
/etc/resolv.conf
file says your nameserver is127.0.0.53
then you likely are using resolvconf and systemd-resolved.1. Make sure your systemd-resolved is installed:
(You might need to temporarily change your resolve.conf to use a well known dns server directly, like Google's, 8.8.8.8, or CloudFlare's 1.1.1.1, or another one)
2. Make sure your configuration files have references to dns servers in them.
For systems that use Debian style
/etc/network/interfaces
config files makes sure you havedns-nameservers
set in the iface section. For example:If you have a newer install you could instead be using Netplan. The config file is usually
/etc/netplan/01-netcfg.yaml
3. Revert changes to resolv.conf
Backout any changes made in step 1. to your
resolv.conf
file. That is, the line withnameserver
should just benameserver 127.0.0.53
4. Restart services
Restart networking
systemctl restart systemd-networking
Restart resolved
systemctl restart systemd-resolved
Had a similar problem upgrading my 22.04 to 24.04. After rebooting, no DNS resolving (pings with IP addresses work though). Tried a similar approach to manually fix resolv.conf (indeed "broken" as well as reinstallation of systemd-resolved). Unfortunately, these steps didn't work for me.
Was able to resolve by following approach: