systemd-resolved ignoring custom DNS servers after Ubuntu 24.04 upgrade
Vahid Shaik
vahid at dnsrobot.net
Thu Mar 5 08:58:27 UTC 2026
Hi,
After upgrading from 22.04 to 24.04, my custom DNS servers in /etc/systemd/resolved.conf keep getting overwritten by NetworkManager.
I set:
[Resolve]
DNS=1.1.1.1 8.8.8.8
FallbackDNS=9.9.9.9
Then ran systemctl restart systemd-resolved, but resolvectl status still shows my ISP's DNS servers. Looks like NetworkManager pushes its own DNS config and wins every time.
I tried setting dns=none in /etc/NetworkManager/NetworkManager.conf but that broke DHCP entirely.
What's the correct way to force custom DNS on 24.04 without fighting NetworkManager? I've seen people suggest netplan but my setup is a simple desktop install, not a server.
To verify which DNS my machine is actually using, I ran a lookup through https://dnsrobot.net/dns-lookup and compared the response IPs against what 1.1.1.1 and my ISP's resolver return. Turns out my machine was still hitting the ISP DNS despite the resolved.conf change.
Anyone else hit this after the 24.04 upgrade?
Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20260305/85837264/attachment.html>
More information about the ubuntu-users
mailing list