[Dnsmasq-discuss] Feature REQ: (yes, I know you've Just Said No)
Mon, 06 Dec 2004 20:04:48 -0800
Simon Kelley wrote:
> What's the advantage in reloading the cache from file on disk when you
> can just reload it from the upstream nameservers? All the information
> is there and you don't have to pay the cost to store it yourself
> (insignificant) or to keep code around to dump and restore it (which
> might not be insignificant, especially on a Linksys plastic router box
> and other embedded platform.)
> I've never tried to measure it, but subjectively I can't feel any
> significant performace loss after emptying the cache.
I don't know how to effectively measure it, but I sit and watch using
iptraf the interval between the requests and the replies from the
upstream servers. It may be iptraf's reporting or it may be real lag.
dnsmasq's cached replies are instantaneous but the same certainly cannot
be said of a request to a nameserver.
Here's what triggered this request:
My external machines number 5, of which 2 are rather busy.
My NNTP server was sucking articles pretty hard during which I ran
jdresolve on one of my log files. jdresolve reported approximately 1.8
seconds per resolution.
Maybe 2 seconds is not terrible but it certainly isn't what I have come
to expect from a caching nameserver either. Multiply 2 seconds by the
(presently) 260 entries in my cache (300 - cca 40 from hosts) to gain
some appreciation for the cache <g>. Granted, usually there is more
time to rebuild the cache than in the above scenario. But my main point
was that I'm trying to decide how many nameservers to use, which are the
fastest of those I have available, how many entries I need in the cache,
Etc and every time I tweak the config I must refresh the cache. I find
As to the bulk something like this would add, make me edit Makefile to
uncomment something in there that will cause "gypsy's fat code" to
compile. Those who have no need are free to skip the edit process.