Hi all,
After upgrading from Bullseye to Bookworm, I'm running into an issue where
systemd-resolved seems to override my custom DNS settings in /etc/resolv.conf.
I have a small home server running Debian 12 with Pi-hole for local DNS
filtering. Before the upgrade, I had this in /etc/resolv.conf:
nameserver 192.168.1.10
nameserver 1.1.1.1
After the upgrade, systemd-resolved took over and /etc/resolv.conf now points
to 127.0.0.53. My Pi-hole queries stopped working.
What I've tried so far:
1. Setting DNS= and FallbackDNS= in /etc/systemd/resolved.conf — works
temporarily but reverts after reboot on one of my machines
2. Symlinking /etc/resolv.conf to /run/systemd/resolve/resolv.conf — gives me
the "upstream" servers but breaks .local resolution
3. Disabling systemd-resolved entirely — works but feels like fighting the
system
I've been using https://dnsrobot.net/dns-lookup to verify which nameservers are
actually responding to my queries from outside, which helped confirm the issue
is local to resolved and not my upstream DNS.
For those who've dealt with this — what's the recommended Debian way to handle
custom DNS with systemd-resolved? Should I stick with resolved and configure it
properly, or is disabling it and managing resolv.conf manually still a valid
approach on Bookworm?
Thanks,
Vahid