Limiting memory usage

Kevin Darcy kcd at daimlerchrysler.com
Thu Apr 25 21:16:24 UTC 2002


phn at icke-reklam.ipsec.nu wrote:

> bert hubert <ahu at ds9a.nl> wrote:
> > In article <aa5n2v$1hj at pub3.rc.vix.com>, phn at icke-reklam.ipsec.nu wrote:
>
> >> I don't think you can (in a reasonable way) limit a nameservers
> >> memory hunger. It's a function of the clients usage and TTL values
> >> set in the RR.  Trying to enforce lower TTL will break the
> >> original RR-publishers suggestion.
>
> > DJBDNS dnscache does this just fine. You tell it how much memory it should
> > use and it uses exactly that, dropping old entries to store new ones.
>
> A nameserver is _supposed_ to cache data up to the time given
> in the original TTL. By silently truncationg the cache it breaks
> the function it's supposed to do.

No, there is no requirement that the entries be held up to the TTL limit. How
could there be such a requirement, since boxes can crash, be rebooted, etc.?
Realistically, to impose such a requirement, it would be necessary to mandate
*persistent* storage, which is unacceptable. The TTL is considered a *maximum*,
not a minimum, and implementations are permitted to pre-expire resource
records. This functionality has, if I'm not mistaken, also been implemented in
the later versions of BIND 9.

Peter, being able to control resource usage is a *good* thing. The fact that
dnscache had this functionality before BIND irks me a little, but that's all in
the past now. Let's not fall into the "not invented here" syndrome; progress is
progress and we should accept is as such.


- Kevin




More information about the bind-users mailing list