[Date Prev][Date Next]
Re: (ITS#5860) slapd memeory leak under openldap 2.4
I just used tcmalloc but I still with the same behavior. slapd doesn't have limit for the cache and then it cannot run large databases.
My DB entrance is not large. One example is :
See above I have 3 DN's.
In 64 bits systems with more memory and small dn's this could be hidden but with the time all physical memory will be used.
So, I made an ldapsearch as (searching a single DN):
time ldapsearch -LLL -x -D "cn=admin,ou=CONTENT,o=domain,c=country" -w secret -b "ou=CONTENT,o=domain,c=country" -H ldap://10.142.15.42:389 'pnnumber=*'| egrep -e '^pnnumber*' |wc -l
So just one of the 3 DNs this DB has. Since the filesize is :
I have part of size load into cache(only for pnnnumber).
But slapd doesn't respect cache limits and load all into memory. It also never release it.
The entrances are not large and caches in the order of 1000 entrances should not make slapd process stay with almost 1GB of memory.
Also once it occupies this memory it never release anymore.
I use lsof and the tcmalloc is being used.
--- On Thu, 1/22/09, Quanah Gibson-Mount <email@example.com> wrote:
> From: Quanah Gibson-Mount <firstname.lastname@example.org>
> Subject: Re: (ITS#5860) slapd memeory leak under openldap 2.4
> To: email@example.com, firstname.lastname@example.org
> Date: Thursday, January 22, 2009, 4:04 PM
> --On Thursday, January 22, 2009 10:01 AM -0800 Rodrigo Costa
> <email@example.com> wrote:
> > Quanah,
> > Just a correction about the man, it was incorrect
> since my man was
> > getting from cache(and so from 2.3 version). Now it is
> > I would like a little more directions about how can be
> compiled openldap
> > 2.4.13 with tcmalloc. Just need to include a lib path?
> Some configure
> > parameter in openldap?
> I use tcmalloc myself, so basically you go and build
> google-perf-tools, and then you preload the library before
> starting slapd. I have a little startup script for slapd:
> ulimit -n 32768
> ulimit -c unlimited
> export LD_PRELOAD=/opt/zimbra/tcmalloc/lib/libtcmalloc.so
> exec /opt/zimbra/openldap/sbin/slapd "$@"
> Quanah Gibson-Mount
> Principal Software Engineer
> Zimbra, Inc
> Zimbra :: the leader in open source messaging and