You are not logged in.

#1 2020-02-15 20:41:37

juphu2Va
Member
Registered: 2019-05-16
Posts: 36

separate nameserver for specific domain.

I have the following setup:

A wireguard setup, where I have a DNS server running on one of the peers (which resolves adresses like "other-node.wg" )

On one peer (my laptop) I want to have name resolution for the wg domain. For that, I have setup systemd-networkd to do the wireguard part and use it's dns for the "wg" domain. systemd-networkd submits this to systemd-resolved.



systemd-resolve --status | awk -v RS="\n\n" '/Servers/' 

shows correctly "wg" for the wg0 interface and "~." for the other main interface.

Problems:

(1) Now, if I run run

dig A archlinux.org

, the DNS-Server from the wg0 interface wrongly answers. (The one from the main interface should answer, since the "wg" domain isn't used)

(2) Name resolution by ping isn't working at all. I suspect it is the fault of /etc/nsswitch.conf, but this file is overwritten after a reboot.

(3) Name resolution by ping isn't working for "wg" Domain.

I noticed: If I manually restart systemd-resolved, the order of the domains "fritz.box" and "wg" in /etc/resolv.conf switched. (I use NetworkManager which connects to my WLAN). This then resolves (1) and (2), but leaves (3)

Offline

Board footer

Powered by FluxBB