[Pdns-users] PDNS Resolver memory leak?

Darren Gamble darren.gamble at sjrb.ca
Wed Oct 10 15:40:59 UTC 2007


Hi Brad,

> I am using this release: pdns-recursor-3.1.4-1.i386.rpm
> 
> The memory usage on the pdns_recursor daemon seems to keep growing
> steadily. I currently have it set to cap at 1 million cache entries.
My
> graphs show me hitting upwards of 1.07 million entries. I am currently
> at 287MB from the initial 226MB that it was steady at for the first 2
> days.
> 
> Is there any known issues with this? I have plenty of RAM but would
like
> to up the cache limit to 4 million and am worried about it eventually
> using up all the system memory. Any help appreciated.

We're running this version ourselves, and haven't had any memory leaks.
Our recursors are capped at 4M entries.

The sample server I've checked has had the process running since March
9.  It's using 1162288B of memory, 1152824 of which is resident.  So, if
there are any memory leaks, they're extremely tiny.  The server is
reasonably busy and hits that memory size within a day of running.

It's normal for the memory size to increase as the server runs, as the
recursor doesn't pre-allocate memory for all of the entries.

That was for a 32-bit x86 machine.  On a 64-bit machine, the memory
usage is quite a bit higher (1.7GB on the machine I peeked at, process
running since Feb 12).  I believe Bert indicated that this is due to
larger pointer sizes.  Still, no leaks, though.

Even if you don't have that much memory, the recursor still runs well on
less.  You'll just have to lower that cache size

>From our experience, at least, I think you can put your mind at ease.
:-)

============================
Darren Gamble
Systems Architect, Regional Services
Shaw Cablesystems GP
630 - 3rd Avenue SW
Calgary, Alberta, Canada
T2P 4L4
(403) 781-4948


More information about the Pdns-users mailing list