45 ms·
This is awesome, thanks You're quite welcome. I assume based on the SmartDNS documentation that the developers had not heard of Unbound as they were making co
by LinuxBender 3y ago
This is awesome, thanks
You're quite welcome. I assume based on the SmartDNS documentation that the developers had not heard of Unbound as they were making comparisons to dnsmasq which I do still use for DHCP now that ISC has deprecated their original dhcp daemon and I found ISC's replacement of Kea to be a little over-complicated for my setup.
I think based on the description of your latency issues that Unbound should fit the needs as you can just load up all the DoT providers you can find and then use Unbound's commands to view the infrastructure stats and even keep running stats if you wish. If you enable extended stats they can be imported into Munin or other performance graphs or just trust it will pick the fastest. Unbound can be tuned as desired or required to use the fastest upstream resolvers. Like you I also increase min-ttl. I also increase that for infrastructure cache ttl as well. This is useful if you should decide to not use DoT/DoH as Unbound can keep track of the name server IP's to reduce time to first packet.
If you temporarily enable query logging to a tmpfs mount to avoid disk write penalty then you can write a script to find the most common names you request and then create a cron job to prefect the NS and/or A records for domains that you visit often. The cron would need to run at a lower interval than your min-ttl if the desire is to keep everything in cache. You can also tell Unbound to prefetch records, it's just not as aggressive or explicit.
# bind8 behavior, useful if not using DoT forwarders
target-fetch-policy: "-1 -1 -1 -1 -1"
# or bind9 behavior sortof, less overhead if using forwarders
target-fetch-policy: "3 2 1 0 0"