Open jonpaulh opened 7 years ago
Some ECS statistics sampling we're contemplating here would benefit from this ability as well. Some sort of wildcarded export method would be interesting, but a full dump would be "good enough."
Also, it may be super useful for dnsdist graceful restart. Our software can handle hard daemon restart. But blast of requests to cold cache can overload upstreams and dnsdist.
I'm thinking about following case:
I think it should reduce downtime a lot.
pavel-odintsov: being able to inject (override? delete?) data into the cache would be useful in a more generic, real-time manner (not just load at launch) as well but that sounds like another ticket.
Yep, that's good idea for out of the band resolution. I.e. I can use custom lua code to get IP for particular qname and then manually inject it into cache.
Original request fixed by #6749
I also started this but never finished: https://github.com/phonedph1/pdns/commit/9217ae0f17f91aa59d6855d86ba0fd01201da08f
Oh, nice! I will try it :)
Firstly apologies if I have placed this incorrectly or not followed any rules.
Short description
In my current configuration I have the following:
mc = newPacketCache(10000, 86400, 0, 60, 60)
getPool(""):setCache(mc)
This is allowing me to cache 10,000 results for 24 hours.
Currently I can remove results like so:
getPool("poolname"):getCache():expungeByName(newDNSName("powerdns.com"), dnsdist.A)
However as I do not know what is in the cache, I cannot remove bad entries or entries I am unaware of using the above method.
If possible adding a new method for example
showCache()
:getPool(""):showCache()
This would then print a list on screen or dump a list to a file with all the cached dns entries.
Other information
I have searched for a possible answer to no avail. I have checked on IRC and it does not seem to be possible at this moment.