[dnsdist] Packetcache expiring

Nemanja Zeljkovic nocturo at gmail.com
Thu Mar 8 17:37:22 UTC 2018


Hi,

I have a problem with packet cache when trying to use it in case of all
servers are down. Namely, I’ve tried setting it up to cache entries for up
to a day in case of a problem but it always expires after 2 minutes.

I’m using following config:
newServer({address="127.0.0.1:54", name="local", qps=1000})
setServerPolicy(firstAvailable) -- first server within its QPS limit
controlSocket('127.0.0.1:5199')
addLocal('0.0.0.0:53', { doTCP=true, reusePort=true })
setKey(“xyz")
webserver(“xyz")
pc = newPacketCache(100000, 86400, 1, 86400, 86400, true)
getPool(""):setCache(pc)
setStaleCacheEntriesTTL(3600)
addACL("0.0.0.0/0”)

start up dnsdist, run a query, getServer(0):setDown() and keep doing dig
and it starts failing after two minutes with:
; <<>> DiG 9.10.3-P4-Ubuntu <<>> example.com @127.0.0.1 -p 53
;; global options: +cmd
;; connection timed out; no servers could be reached

In my understanding of the packet cache, it would cache for up to 86400 if
the cache is expired, but it looks like cache gets expunged since doing
stats on the cache:
Running:
dnsdist 1.2.1 (Lua 5.1.4)
Enabled features: dnscrypt libsodium protobuf re2 systemd

on Ubuntu 16.04.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.powerdns.com/pipermail/dnsdist/attachments/20180308/736f6381/attachment.html>


More information about the dnsdist mailing list