Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DNS caching and DNS query statistics. #1453

Open
MasterArmory opened this issue Mar 6, 2020 · 20 comments
Open

DNS caching and DNS query statistics. #1453

MasterArmory opened this issue Mar 6, 2020 · 20 comments

Comments

@MasterArmory
Copy link

DNS Caching:
This is helpful in speeding up requests. If it's currently implemented, I am not aware of it.

DNS Query Statistics:
This is a feature form PiHole. On the dashboard, I would like to see a pie chart of where my DNS resolutions are originating. As a bouns, the average response time from each source would also be good to know.

Thank you.

@ameshkov
Copy link
Member

ameshkov commented Mar 6, 2020

This is helpful in speeding up requests. If it's currently implemented, I am not aware of it.

It is, there are no stats, though.

This is a feature form PiHole. On the dashboard, I would like to see a pie chart of where my DNS resolutions are originating. As a bouns, the average response time from each source would also be good to know.

Could you please explain what exact stats on this pie chart would you like to see?

@MasterArmory
Copy link
Author

MasterArmory commented Mar 6, 2020

Could you please explain what exact stats on this pie chart would you like to see?

Yes, I would like to see the total for responses for each DNS Server used and the cache.
For example: If I have 200 DNS lookups.
I would like to see a chart showing:

  • 85 came from the cache
  • 62 came from 9.9.9.9
  • 50 came from 1.1.1.1
  • 3 came from 8.8.8.8

Extra credit if the pie chart or graph also showed the average response time for each DNS Server.

  • 85 came from the cache -Agv. 10ms
  • 62 came from 9.9.9.9 -Avg. 100ms
  • 50 came from 1.1.1.1 -Avg. 32ms
  • 3 came from 8.8.8.8 -Avg. 24ms

@ariqmuhammadt
Copy link

I think it doesn't have dns caching because i can't find it listed as a feature, it is better if you add stats or status in the query if it cached or not and response time like in the PiHole. Thanks

@ameshkov
Copy link
Member

Well, it's just so basic that listing it as a feature would be strange.

Currently, you can configure just the DNS cache size:
https://github.com/AdguardTeam/AdGuardHome/wiki/Configuration#configuration-file

@alexiri
Copy link

alexiri commented Apr 14, 2020

Those statistics would be a great addition! It would be nice if we could also see what was in the cache.

@timkgh
Copy link

timkgh commented Sep 13, 2021

+1 for cache stats: hits, misses, eviction because of TTL vs no room in cache, etc. It helps with cache sizing also to see how the cache is being used.

@timkgh
Copy link

timkgh commented Sep 21, 2021

Stats per upstream would be very useful also. There's "Average processing time" but I would like to see numbers per upstream.

@yuxuan0107
Copy link

我也需要这个功能

@ainar-g ainar-g changed the title Feature Requests - DSN caching and DNS query statistics. DNS caching and DNS query statistics. Jan 27, 2022
@becks0815
Copy link

Also +1 for more etailed stats. At the moment I am blind concernning relevant settings like TTL data, cache size usage (percentage of cache hits) or different dns servers reaction times, amount of requests sent to the dns servers or even cache usage (percentage of the assigned memory)

@adrianmace
Copy link

The DNS pie chart would also give insights into how the weighted load balancing algorithm is working.

My AGH is configured with multiple upstream providers like so, and racing them against each other using Parallel Requests.

# NextDNS
45.90.28.0
45.90.30.0
# Cloudflare (with enhanced Security)
1.1.1.2
1.0.0.2
# Quad 9 (with ECS)
9.9.9.11
149.112.112.11
# Google
8.8.8.8
8.8.4.4

Through the query log I can see that NextDNS is winning most of the time, but I'd like a visualisation with percentage breakdown on the home screen.

@ely105
Copy link

ely105 commented Mar 9, 2023

+1 on this. It would be nice to have simple cache stats on the dashboard. Cache hits % is mostly useful to see how effective the cache is for the time period displayed.

@Kani3D

This comment was marked as duplicate.

@peepsnet
Copy link

peepsnet commented Apr 8, 2023

I want to see this too...
On the dashboard page...

Upstream DNS Server Requestes Avg
Cached 12522 2ms
tls://1.1.1.1 9855 19ms
https://1.1.1.1/query 5578 16ms
8.8.8.8 452 33ms

#2013

@gyCfjSnO

This comment was marked as off-topic.

adguard pushed a commit that referenced this issue Aug 9, 2023
Updates #1453.

Squashed commit of the following:

commit f08f68e
Merge: b70b088 54aee22
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Aug 8 19:04:06 2023 +0300

    Merge branch 'master' into 1453-stats-tests

commit b70b088
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Aug 3 19:32:04 2023 +0300

    stats: imp code

commit c341012
Merge: a2ac8c3 5eb3cd0
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Aug 3 13:36:24 2023 +0300

    Merge branch 'master' into 1453-stats-tests

commit a2ac8c3
Author: Ildar Kamalov <ik@adguard.com>
Date:   Thu Aug 3 13:25:12 2023 +0300

    client: add top upstreams and average processing time tables

commit 1111894
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Aug 1 17:24:57 2023 +0300

    stats: imp docs

commit 904cf81
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Mon Jul 31 17:34:06 2023 +0300

    stats: imp code

commit 34f0c96
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Mon Jul 31 15:43:46 2023 +0300

    all: imp docs

commit 2cb2d0d
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Fri Jul 28 17:24:31 2023 +0300

    all: imp code

commit 5251a89
Merge: b6c2b12 300821a
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Jul 27 20:34:39 2023 +0300

    Merge branch 'master' into 1453-stats-tests

commit b6c2b12
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Jul 27 20:32:18 2023 +0300

    stats: imp code

commit 5546b82
Merge: 8a3d6b1 5f8fa00
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Jul 27 14:24:01 2023 +0300

    Merge branch 'master' into 1453-stats-tests

commit 8a3d6b1
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Jul 27 14:17:47 2023 +0300

    all: imp code

commit 2a48001
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Jul 25 18:27:20 2023 +0300

    all: imp docs

commit 3dd2189
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Jul 25 16:00:39 2023 +0300

    all: imp naming

commit 6124456
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Jul 20 16:15:56 2023 +0300

    all: add upstreams avg processing time

commit 187ad0c
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Jul 18 16:42:19 2023 +0300

    all: add top upstreams
@ainar-g ainar-g mentioned this issue Aug 9, 2023
3 tasks
adguard pushed a commit that referenced this issue Aug 9, 2023
Updates #1453.

Squashed commit of the following:

commit 81105a5
Author: Ainar Garipov <A.Garipov@AdGuard.COM>
Date:   Wed Aug 9 17:51:42 2023 +0300

    client: fix total for upstream table
@schzhn
Copy link
Member

schzhn commented Sep 8, 2023

Upstream statistics added in v0.107.37.

@schzhn schzhn closed this as completed Sep 8, 2023
@ainar-g
Copy link
Contributor

ainar-g commented Sep 8, 2023

@schzhn, there are still cache statistics to figure out.

@ainar-g ainar-g reopened this Sep 8, 2023
@timkgh
Copy link

timkgh commented Sep 10, 2023

@ainar-g It would also be useful to add stats for parental_block_host and safebrowsing_block_host response times under "Average processing time".

@ainar-g
Copy link
Contributor

ainar-g commented Sep 11, 2023

@timkgh, I'm not entirely sure what you mean, but please make a separate feature request about that.

@timkgh
Copy link

timkgh commented Sep 11, 2023

@timkgh, I'm not entirely sure what you mean, but please make a separate feature request about that.

If "browsing security" and "parental control" are enabled in "General settings", then standard-block.dns.adguard.com and family-block.dns.adguard.com are used for these features, via DNS queries. The Dashboard UI should also show DNS stats for these 2 servers, in the "Average processing time" card.
I think it's relevant in this issue as it also relates to DNS stats.

@zgqq
Copy link

zgqq commented Jul 11, 2024

Need to hit cache stats.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests