[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: restricting slapd memory consumption

Pierangelo Masarati schrieb:
Ralf Narozny wrote:

Pierangelo Masarati schrieb:
Buchan Milne wrote:

/me notes that it would be nice to have more detail on the entry cache available via back-monitor, such as the number of entries in the cache, and the amount of entry cache that is used ...

Something like

bash-3.1$ ldapsearch -x -H ldap://:9011 -b 'cn=Databases,cn=Monitor' \
    '(objectclass=olmBDBDatabase)' @olmBDBDatabase

I configured the slapd to create a monitor, but the information you want is not present.

Maybe I missed something to configure, but the manual is not too thouroughly written by now ;-)

database monitor
rootdn         "cn=root,cn=monitor"
rootpw         {SSHA}...

ldapsearch -D 'cn=root,cn=monitor' -W -b 'cn=Databases,cn=Monitor' 'objectclass=*' '*' '+'

(as far as I understood, this should show all data for the entries below cn=Databases,cn=Monitor')

Well, that information is only available since OpenLDAP 2.4; I infer you're using an earlier distribution. In any case, the monitor has nothing to do with the entry cache configuration, it only shows the current usage. Refer to slapd.conf or back-config for what is configured for your system.

Yep, as I wrote in my initial mail, we are using 2.3.32 (for testing so far).

And I wrote that we are using BDB which is configured to use 4GB of shared mem. The only problem I have is that with 1000000 entries configured as entry cache, slapd uses 11GB out of 16 GB of RAM after the insert with ldapadd. Which makes it use 7GB for entry cache (and whatever else).

Our entries have (in LDIF of course) an average size of below 200 Bytes. So taking 6GB out of the 7GB used as size of the entry cache, it would mean that each entry consumes about 6K of RAM. Is that correct?

If so, is there any documentation on how to configure the slapd for a larger amount of entries like ours?


Ing. Pierangelo Masarati
OpenLDAP Core Team

SysNet s.r.l.
via Dossi, 8 - 27100 Pavia - ITALIA
Office:  +39 02 23998309
Mobile:  +39 333 4963172
Email:   pierangelo.masarati@sys-net.it