OpenLDAP Tuning Keys
|This article applies to the following ZCS versions.|
OpenLDAP Tuning Keys
Starting with ZCS 6.0, the configuration is stored in a database. This allows the ability to make changes to the OpenLDAP configuration on the fly. To support this, a number of keys were added to Localconfig. When modified via zmlocalconfig, the values will automatically be updated in the OpenLDAP server configuration within 2 minutes.
OpenLDAP Common keys
These keys set the general, or common, settings for the slapd process. They are apply to both the master and replica servers.
- Set the debugging level to be used. The default is 49152
zmlocalconfig -e ldap_common_loglevel=49152
- Set the threads count to an appropriate level. The ZCS default is 8, which is fine for 1 or 2 CPU servers. The general rule of thumb is 4 threads for every real core.
zmlocalconfig -e ldap_common_threads=8
- Set whether or not an encrypted connection is required to establish communication with the LDAP server. 0 for no, 1 for yes. Default is 0.
- Set the toolthreads count to an appropriate level. The ZCS default is 1. It should be set to the number of real cores you have available. The purpose of the toolthreads setting is to decrease the amount of time it takes to slapadd a database.
zmlocalconfig -e ldap_common_toolthreads=1
- Set the write timeout for how long to wait for a write to succeed. The default is 0, which is infinitely. Otherwise, forcefully close the connection after the specified number of seconds.
zmlocalconfig -e ldap_common_writetimeout=0
OpenLDAP Primary Database keys
These keys apply to the primary LDAP database. They are apply to both the master and replica servers.
- The number of entries to free when the entry cache gets full. Default is 1.
zmlocalconfig -e ldap_db_cachefree=1
- The entry cachesize for the primary database. The number set should be the number of configured active accounts and the number of configured active domains. The default is 10000.
zmlocalconfig -e ldap_db_cachesize=10000
- The idlcachesize for the primary database. The number set should be the same as the cachesize setting. The default is 10000.
zmlocalconfig -e ldap_db_idlcachesize=10000
- The dn entry cachseize for the primary database. It is highly recommended to leave it at the default value of zero, which means an unlimited DN cache. If it is set to a non-zero value, it should be no less than two times the entry cache.
zmlocalconfig -e ldap_db_dncachesize=0
ldap_db_checkpoint = 64 5 ldap_db_dncachesize = 0 ldap_db_idlcachesize = 10000 ldap_db_shmkey = 0
OpenLDAP Accesslog Database Keys
ldap_accesslog_cachefree = 1 ldap_accesslog_cachesize = 10000 ldap_accesslog_checkpoint = 64 5 ldap_accesslog_dncachesize = 0 ldap_accesslog_idlcachesize = 10000 ldap_accesslog_shmkey = 0
OpenLDAP Overlay Keys
OpenLDAP Accesslog Overlay Keys
ldap_overlay_accesslog_logpurge = 01+00:00 00+04:00
OpenLDAP Syncprov Overlay Keys
ldap_overlay_syncprov_checkpoint = 20 10 ldap_overlay_syncprov_sessionlog = 500