I keep seeing this confusion in various posts on the forum so I'm adding this to the thread.
You do not need to use any other programs like Unbound, Stubby or DNS-Over-Https. Those were the old way of manually adding encrypted DNS to OpenWrt and extending DNSMasqs so it could do encrypted lookups.
AGH does it all internally and will do any variant of encrypted dns. DoH, DoT, DoQ. All you have to do is pick the provider you wish to use.
There is a problem that still bothers me. Whenever my R2S restarts, AGH will always be unable to block it. To save space, I have disabled saving QueryLog.
When it boots up, it will use dnsmasqs DNS to do NTP and updates. Then AGH will load and provide DNS to the rest of your network. That's the way it has to load.
is AGH started as a service? If you do not have sudo installed then AGH will fail to install as a service and thus not restart when the router reboots.
Install sudo and reinstall AGH using the script. This will properly setup AGH as a service and thus auto start when you reboot.
Yes that is the package. Yes. reinstall with the script and it will setup AGH as a service. It should leave your agh.yaml file alone so all your config should stay as it was. Back it up before hand in case however.
The script also accepts some options:
-c <channel> to use specified channel.
-r to reinstall AdGuard Home;
-u to uninstall AdGuard Home;
-v for verbose output;
Note that options -r and -u are mutually exclusive.
Technically you should uninstall AGH and have your yaml file backed up first.
Then remove the /opt/AdGuardHome folder.
Then properly reinstall it. Just so you have a clean install.
curl -s -S -L https://raw.githubusercontent.com/AdguardTeam/AdGuardHome/master/scripts/install.sh | sh -s -- -v