with additional error information explaining the problem.

Entry DN:

cn=database_name, cn=ldbm database, cn=plugins, cn=config

Valid Range:

500Kb to 4 GB for 32-bit platforms, and 500Kb to 2^64 -1 for 64-bit

 

Platforms

Default Value:

10,485,760 (10Mb)

Syntax:

Integer

Example:

nsslapd-cachememsize: 10485760

nsslapd-cachesize:

This performance tuning attribute specifies the cache size in terms of the entries it can hold. However, it is simpler to limit by memory size only (using the nsslapd-cachememsizeattribute). If you attempt to set a value that is not a number or is too big for a 32-bit signed integer, you will receive an LDAP_UNWILLING_TO_PERFORM error message with additional error information explaining the problem.

The server has to be restarted for changes to this attribute to take effect.

Entry DN:

cn=database_name, cn=ldbm database, cn=plugins, cn=config

Valid Range:

1 to 2,147,483,647 (or -1 which means limitless) entries

Default Value:

-1

Syntax:

Integer

Example:

nsslapd-cachesize: -1

When the server receives a search request, it adds entries to the entry cache. The nsslapd- cachesize attribute specifies how many entries can be cached in the entry cache. The nsslapd- cachememsize attribute specifies the total memory space the entry cache may consume. These two attributes control how much the entry cache can grow. When the server reaches the limit specified by either cachesize or cachememsize, whichever comes first, it removes the least recently used entries from the entry cache to make room for new entries. For optimum search performance, all directory entries should be held in the entry cache.

Tuning nsslapd-cachememsize (assume nsslapd-cachesize is set to –1) is very straightforward:

Step 1: Set nsslapd-cachememsizeto some guessed value.

Step 2: Prime the server by executing ldapsearch command 1.

Step 3: Execute an ldapsearch command (label it as “command 3”) to discover attributes related to the entry cache:

#./ldapsearch –p PORT –b “cn=monitor,cn=DATABASE_ROOT,cn=ldbm database, cn=plugins, cn=config” –D “cn=directory manager” –w PASSWORD “objectclass=*” grep entrycache

entrycachehits: 7

entrycachetries: 1000015

entrycachehitratio: 0

currententrycachesize: 1073739367

maxentrycachesize: 1073741823

currententrycachecount: 398030

maxentrycachecount: -1

9