6.3. Re-enabling database and entry cache auto-sizing
Red Hat recommends using the built-in cache auto-sizing feature for optimized performance. Red Hat does not recommend setting cache sizes manually.
By default, the IdM Directory Server automatically determines the optimal size for the database cache and entry cache. Auto-sizing sets aside a portion of free RAM and optimizes the size of both caches based on the hardware resources of the server when the instance starts.
Use this procedure to undo custom database cache and entry cache values and restore the cache auto-sizing feature to its default values.
|
This settings controls how much free RAM is allocated for auto-sizing the database and entry caches. A value of |
Default value |
|
Valid range |
|
Entry DN location |
|
|
This value sets the percentage of free memory determined by |
Default value |
|
Valid range |
|
Entry DN location |
|
Conditions préalables
- You have previously disabled database and entry cache auto-tuning.
Procédure
Stop the Directory Server.
[root@server ~]# systemctl stop dirsrv.target
Backup the
/etc/dirsrv/slapd-instance_name/dse.ldif
file before making any further modifications.[root@server ~]# *cp /etc/dirsrv/slapd-instance_name/dse.ldif \ /etc/dirsrv/slapd-instance_name/dse.ldif.bak.$(date "+%F_%H-%M-%S")
Edit the
/etc/dirsrv/slapd-instance_name/dse.ldif
file:Set the percentage of free system RAM to use for the database and entry caches back to the default of 10% of free RAM.
nsslapd-cache-autosize: 10
Set the percentage used from the free system RAM for the database cache to the default of 25%:
nsslapd-cache-autosize-split: 25
-
Save your changes to the
/etc/dirsrv/slapd-instance_name/dse.ldif
file. Start the Directory Server.
[root@server ~]# systemctl start dirsrv.target
Verification steps
Display the values of the
nsslapd-cache-autosize
andnsslapd-cache-autosize-split
attributes and verify they have been set to your desired values.[root@server ~]# ldapsearch -D "cn=directory manager" -w DirectoryManagerPassword -b "cn=config,cn=ldbm database,cn=plugins,cn=config" | grep nsslapd-cache-autosize nsslapd-cache-autosize: *10 nsslapd-cache-autosize-split: 25
Ressources supplémentaires
- nsslapd-cache-autosize in Directory Server 11 documentation