optimistic dns caching
Prerequisites
-
[X] I have checked the Wiki and Discussions and found no answer
-
[X] I have searched other issues and found no duplicates
-
[X] I want to report a bug and not ask a question or ask for help
-
[X] I have set up AdGuard Home correctly and configured clients to use it. (Use the Discussions for help with installing and configuring clients.)
Platform (OS and CPU architecture)
FreeBSD, AMD64 (aka x86_64)
Installation
GitHub releases or script from README
Setup
On a router, DHCP is handled by the router
AdGuard Home version
v0.107.44
Action
optimistic dns caching enabled, dns cache size doubled, minimal ttl 60 seconds (maximal ttl is empty)
Expected result
expecting of reduction of latency for all dns requests after first resolution
Actual result
one request of 20 or 30 on average resolves es expected (under 10 ms) all else obviously requests each time clients request it
Additional information and/or screenshots
No response
We cannot reproduce that, see screenshot. Note that the amount of flitering rules as well as response time from the parental-control and safe-browsing services will affect the precise numbers. If you still think there is a bug, please inspect the query log, especially whether or not the (served from cache) mark is set, and try a different upstream, as some upstreams have known issues with cacheability.
hi
sorry for delay
i had small misunderstanding of situation. after experimentation i discovered next:
apparently, dns cache works per client. not for all clients in network:
there is performance issue when any filter list enabled.
pretext os:opnsense, cpu:3cores, ram:5gb, 4 interfaces wan included, 3 interfaces bounded to Adguard (without wan), dns sources:local unbound on Opnsense + 3 (https://dns10.quad9.net/dns-query 8.8.8.8 1.1.1.1).
if i use unbound i have up to 2 sec of delay in browser:
if i use adguard without any blocklist enabled it will be same-ish
but, if i use any blocklist it will become 8+sec on browser end before page starts to load:
if on page several sources present it adds up quickly, page may just hang with blank content (due to timeout i believe)
by "any blocklist" i am serious, any blocklist. if i will enable "Dandelion Sprout's Game Console Adblock List" only, which is tiny, i will get 8+ seconds in browser. if i add all blocklists in the menu it will it will work same-ish as with one enabled.
from Adguerd statistics point of view situation looks like good:
ps: i had reinstalled Adguard several days before in hope it will help. and i was very vigilant to make sure that yaml config file not existing before install. configured by hands after installation from screech.
something went wrong :)