brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: AdGuard Home can send one domain to a different DNS server

Network and access
~/tips/tip-adguard-home-upstream-per-domain

https://dns.quad9.net/dns-query

Resolve your local or company domain with its own DNS server while the rest goes upstream.

A home router knows the names of the devices on your network; the public upstream does not. In AdGuard Home’s upstream list, square brackets send one domain to its own server.

In Settings, DNS settings, Upstream DNS servers, put the special line next to your normal upstreams:

https://dns.quad9.net/dns-query
[/home.example/]192.0.2.1
[/corp.example/lab.example/]203.0.113.53

Anything ending in home.example now goes to the router at 192.0.2.1, and both company domains go to 203.0.113.53. Everything else uses the first line. You can list several domains between the slashes.

There is a special value #, which the docs describe as “use the default servers”. It is how you make an exception inside an exception:

[/example.com/]203.0.113.53
[/www.example.com/]#

Here example.com goes to the internal server, except www.example.com, which goes to the normal upstreams.

One thing I’d check is reverse lookups. For client names in the query log, AdGuard Home has a separate private reverse DNS setting; pointing that at your router as well gives you names instead of bare addresses.

If you edit AdGuardHome.yaml instead of the web UI, stop the service first. The docs warn a running AdGuard Home overwrites the file.

Further reading: AdGuard Home configuration: upstreams for domains

Going deeper: Guide: AdGuard Home with Unbound: resolve DNS yourself instead of asking Cloudflare or your ISP

More Network and access tips scp -3 alice@server-a:/var/backups/db.sql.gz bob@server-b:/srv/restore/ tailscale exit-node suggest tailscale lock sign nodekey:1abddef1 tlpub:abcdef12 wg genpsk > peer1.psk Table = off All Network and access tips (163) All topics

Link