mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-28 04:34:54 -04:00
Report Cache NSEC auxilary database size
This commit is contained in:
parent
85bfcaeb2e
commit
62dd9ec9c1
1 changed files with 9 additions and 0 deletions
|
|
@ -1262,6 +1262,8 @@ dns_cache_dumpstats(dns_cache_t *cache, FILE *fp) {
|
|||
"cache records deleted due to TTL expiration");
|
||||
fprintf(fp, "%20u %s\n", dns_db_nodecount(cache->db, dns_dbtree_main),
|
||||
"cache database nodes");
|
||||
fprintf(fp, "%20u %s\n", dns_db_nodecount(cache->db, dns_dbtree_nsec),
|
||||
"cache NSEC auxiliary database nodes");
|
||||
fprintf(fp, "%20" PRIu64 " %s\n", (uint64_t)dns_db_hashsize(cache->db),
|
||||
"cache database hash buckets");
|
||||
|
||||
|
|
@ -1329,6 +1331,8 @@ dns_cache_renderxml(dns_cache_t *cache, void *writer0) {
|
|||
|
||||
TRY0(renderstat("CacheNodes",
|
||||
dns_db_nodecount(cache->db, dns_dbtree_main), writer));
|
||||
TRY0(renderstat("CacheNSECNodes",
|
||||
dns_db_nodecount(cache->db, dns_dbtree_nsec), writer));
|
||||
TRY0(renderstat("CacheBuckets", dns_db_hashsize(cache->db), writer));
|
||||
|
||||
TRY0(renderstat("TreeMemTotal", isc_mem_total(cache->mctx), writer));
|
||||
|
|
@ -1394,6 +1398,11 @@ dns_cache_renderjson(dns_cache_t *cache, void *cstats0) {
|
|||
CHECKMEM(obj);
|
||||
json_object_object_add(cstats, "CacheNodes", obj);
|
||||
|
||||
obj = json_object_new_int64(
|
||||
dns_db_nodecount(cache->db, dns_dbtree_nsec));
|
||||
CHECKMEM(obj);
|
||||
json_object_object_add(cstats, "CacheNSECNodes", obj);
|
||||
|
||||
obj = json_object_new_int64(dns_db_hashsize(cache->db));
|
||||
CHECKMEM(obj);
|
||||
json_object_object_add(cstats, "CacheBuckets", obj);
|
||||
|
|
|
|||
Loading…
Reference in a new issue