2

My current networking setup (on Arch Linux) involves:

  • stubby to resolve DNS requests with DNS-over-TLS.
  • dnsmasq to cache DNS queries (and nothing else).
  • openresolv to manage resolv.conf.
  • NetworkManager to set-up and tear-down network connections.

I have stubby listening on locahost on some random port, dnsmasq listening on localhost:53 and resolving DNS queries through stubby, and openresolv is set up to put localhost in resolv.conf and provide any other DNS entry (for example those obtained through DHCP by NetworkManager) to dnsmasq via separate configuration files:

# /etc/resolvconf.conf
name_servers=127.0.0.1

dnsmasq_conf=/etc/dnsmasq-conf.conf
dnsmasq_resolv=/etc/dnsmasq-resolv.conf

However, at the moment those extra entries are being ignored.

What is the best way to use these entries only when connected to one of a few whitelisted networks?

To clarify, I know that with NetworkManager I can override the DNS entries provided over DHCP on a network-by-network basis, but what I would like to do is the opposite: use stubby by default and the DHCP entries for only one or two networks, as needed.

1 Answer 1

0

NetworkManager can create a custom zone per Wireless network see:

https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/configuring_and_managing_networking/index

Section 9.2. Configuring a Wi-Fi connection using nmcli

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .