Chapter 7. Monitoring the database activity Administrators should monitor the database activity to ensure that tuning settings, such as caches, are properly configured. 7.1. Monitoring the database activity using the command line To display the monitoring activity using the command line, display the dynamically-updated read-only attributes stored in the cn=monitor,cn= database_name ,cn=ldbm database,cn=plugins,cn=config . Procedure To display the current activity of a database, enter: # dsconf -D " cn=Directory Manager " ldap://server.example.com monitor backend userRoot This command displays the activity of the userRoot database. Additional resources Database monitoring attributes 7.2. Monitoring the database activity using the web console In the web console, Directory Server displays the values of the dynamically-updated read-only monitoring attributes from the cn=monitor,cn= database_name ,cn=ldbm database,cn=plugins,cn=config in the `Monitoring \u0301 tab. Procedure Navigate to Monitoring Database database name . Display the cache values on the Entry Cache and DN Cache tabs. Additional resources Database monitoring attributes 7.3. Database monitoring attributes Table 7.1. Inheritance settings Attribute Description readonly Indicates whether the database is in read-only mode ( 1 ) or in read-write mode ( 0 ). entrycachehits The total number of successful entry cache lookups. The value is the total number of times the server could retrieve an entry from the entry cache without reloading it from the database. entrycachetries The total number of entry cache lookups since you started the instance. The value is the total number, since the instance has been started, Directory Server tried to retrieve entry from the entry cache. entrycachehitratio The number of entry cache tries to successful entry cache lookups. This number is based on the total lookups and hits since you last started the instance. The closer the entry cache hit ratio is to 100%, the better. Whenever an operation attempts to find an entry that is not present in the entry cache, the server needs to access the database to obtain the entry. Thus, as this ratio drops towards zero, the number of disk accesses increases, and directory search performance decreases. To improve this ratio, increase the size of the entry cache of the database. To improve this ratio, increase the size of the entry cache by increasing the value of the nsslapd-cachememsize attribute in the cn= database_name ,cn=ldbm database,cn=plugins,cn=config entry. currententrycachesize The total size, in bytes, of directory entries currently present in the entry cache. To increase the size of the entries which can be present in the cache, increase the value of the nsslapd-cachememsize attribute in the cn= database_name ,cn=ldbm database,cn=plugins,cn=config entry. maxentrycachesize The maximum size, in bytes, of directory entries that Directory Server can maintain in the entry cache. To increase the size of the entries which can be present in the cache, increase the value of the nsslapd-cachememsize attribute in the cn= database_name ,cn=ldbm database,cn=plugins,cn=config entry. currententrycachecount The current number of entries stored in the entry cache of a given backend. maxentrycachecount The maximum number of entries stored in the entry cache of a database. To tune this value, increase the value of the nsslapd-cachesize attribute in the cn= database_name ,cn=ldbm database,cn=plugins,cn=config entry. dncachehits The number of times the server could process a request by obtaining a normalized distinguished name (DN) from the DN cache rather than normalizing it again. dncachetries The total number of DN cache accesses since you started the instance. dncachehitratio The ratio of cache tries to successful DN cache hits. The closer this value is to 100%, the better. currentdncachesize The total size, in bytes, of DN currently present in the DN cache. To increase the size of the entries which can be present in the DN cache, increase the value of the nsslapd-dncachememsize attribute in the cn= database_name ,cn=ldbm database,cn=plugins,cn=config entry. maxdncachesize The maximum size, in bytes, of DNs that Directory Server can maintain in the DN cache. To increase the size of the entries which can be present in the cache, increase the value of the nsslapd-dncachememsize attribute in the cn= database_name ,cn=ldbm database,cn=plugins,cn=config entry. currentdncachecount The number of DNs currently present in the DN cache. maxdncachecount The maximum number of DNs allowed in the DN cache.

Commands:
dsconf -D " cn=Directory Manager " ldap://server.example.com monitor backend userRoot