#2739 Increase the default nsslapd-cachememsize
Closed: Fixed None Opened 11 years ago by mkosek.

https://bugzilla.redhat.com/show_bug.cgi?id=820003 (Red Hat Enterprise Linux 6)

Description of problem:

I've seen memory leaks in my 389-ds processes, ending in the OOM-killer killing
off my dirsrv processes. This has also been reported by others on the
freeipa-users mailing list an other users of 389-ds.

After discussing with Rich Megginson this could be the work of a too low
default nsslapd-cachememsize. The default  nsslapd-cachememsize is 10MB.
According to the 389-ds tuning guide this value should be set to at least 2 x
the id2entry.db4 file. Even a small IPA installation of 37 users and 52 hosts
has a id2entry.db4 file of 7.2MB. This suggests that the default size is too
small.

Rich M. advised that auto-tuning has proven to be more error prone than useful
in the past, however tuning of the nsslapd-cachememsize parameter should be
done on a per-environment basis.

After speaking to Rich M, I suggest two changes to be taken into consideration.

First, significantly increase the default nsslapd-cachememsize, as the default
seem to be way to low even for small installation.

Second, make the nsslapd-cachememsize parameter tunable through the IPA cli/ui,
with a reference from the documentation that this should be performed as a part
of the post-installation process of an IPA environment.

Perhaps there could even be a suggested size based upon the actual installation
given in the IPA cli/ui?

Opening this request as agreed with richm on IRC.

We will increase the default and we also need to doc it. When we close the ticket please open a doc task.

Nalin and Nathan assess this as a minor fix.

I don't think this is going to require often-enough tuning to write a CLI for it. I think documentation is going to be enough.

Discussed this with Simo and Rich. It would be nice if 389-ds could automatically manage the cache size, or at least whine if it is too small for the current configuration. Opened ticket https://fedorahosted.org/389/ticket/409 for the whining.

I'm not sure we really need to tweak the default size. I created an install with 500 users and used just 6MB of the cache. Add in a bunch of hosts and it would likely still be below the default cache size.

I guess it depends on what our average server size is. We can bump this up to 2x I suppose but I don't want to allocate RAM to 389-ds that isn't going to be used efficiently.

Fixed in 1.2.11.8

If the cache is too low you should get a warning like:

[14/Aug/2012:09:22:25 -0400] - WARNING: userRoot: entry cache size 1048576B is less than db size 2703360B; We recommend to increase the entry cache size nsslapd-cachememsize.

Moving closed RC1 tickets to Beta 3.

Metadata Update from @mkosek:
- Issue assigned to rcritten
- Issue set to the milestone: FreeIPA 3.0 Beta 3

7 years ago

Login to comment on this ticket.

Metadata