Mariusz Gronczewski <x...@devrandom.pl> writes:

> Offtopic but since Debian switched to systemd for DNS management on
> VPNs and suc I need to restart it sometimes multiple times to just get
> "right" DNS servers, because there appears to be no notion of priority:
>
> https://github.com/systemd/systemd/issues/27543
>
> so now any time I connect to work (just openvpn tunnel, nothing fancy)
> I need to spam
>
> systemclt restart systemd-resolved ; sleep 1 ; cat /etc/resolv.conf
>
> few times till the dice rolls the right order of DNS servers...

Interesting. I leaped on systemd-networkd and -resolved when I read
years ago it added interface specific DNS support. So now my local DNS
(dnsmasq in the router) handles my home network and what goes out via
the VPN (i.e. tun0 or wg0 these days) uses the VPN's DNS. Or if the VPN
is off, the local DNS forwards queries to DHCP assigned DNS. I see no
issues although I don't have the kind of VPN where some external traffic
goes through it only but might work for that too. For me the default was
that systemd-resolved dutifully spammed all DNS queries to all DNS
servers through all interfaces.

This interface specific DNS was a little hard to setup as I
recall. Easier with WG than OpenVPN.

Reply via email to