dnsmasq - ArchWiki
wiki.archlinux.org › title › DnsmasqDNS addresses file and forwarding. After configuring dnsmasq, you need to add the localhost addresses as the only nameservers in /etc/resolv.conf. This causes all queries to be sent to dnsmasq. Since dnsmasq is a stub resolver not a recursive resolver you must set up forwarding to an external DNS server.
dnsmasq - Debian Wiki
https://wiki.debian.org/dnsmasqUsing dnsmasq to cache DNS queries for the local machine is a bit tricky (unless you're using NetworkManager, see below), since all DNS queries from the local machine need to go to dnsmasq, while at the same time, dnsmasq must be configured to forward all those queries to upstream DNS servers.
dnsmasq - Debian Wiki
wiki.debian.org › dnsmasqDnsmasq is a lightweight, easy to configure, DNS forwarder and DHCP server. It is designed to provide DNS and optionally, DHCP, to a small network. It can serve the names of local machines which are not in the global DNS.