The database cache

To minimize delays that occur when users, servers, or API programs open and close databases on a server, each server maintains a database cache. When a database closes and there are no users or processes using the database, Domino® puts the database in the cache so it can close it quickly. The database remains in the cache until it's opened again or for about 15 to 20 minutes, whichever comes first. Databases in the cache can be opened quickly.

The database cache is available to the first process that starts on a machine and to any processes spawned from it. If you run the Domino Administrator and the Domino server on the same machine -- a configuration that is not recommended -- start the server before you start the Domino Administrator. If you start the Domino Administrator first, it owns the cache and prevents the Domino server from using it effectively.

By default, the number of databases that the cache can store simultaneously is the greater of these values:

  • The value of the NSF_Buffer_Pool_Size setting in the NOTES.INI file, divided by 300K
  • 25

To change this limit, add the NSF_DbCache_Maxentries setting to the NOTES.INI file or increase physical memory. Increasing the database cache size improves system performance but requires additional memory. The minimum number of databases allowed in the cache at one time is 25; the maximum is 2,000.

The actual number of databases allowed in the cache is 1.5 times the maximum allowed. This buffer increases the chance that when a user opens a database from the cache, Domino can return the database to the cache when the user closes it.

Databases are dropped from the cache by an "ager" thread that performs necessary writes, de-allocates memory, and completes other tasks to close databases. This process happens over a period of 15 to 20 minutes. Ideally, databases are dropped from the cache in time to allow new databases to be added without exceeding the maximum databases allowed in the cache. However, if the maximum is exceeded, one of the following occurs:

  • If the number of databases in the cache is less than the maximum allowed times 1.5, when a database is closed it is added to the cache, and the ager accelerates to reduce the number of databases to the maximum allowed. This action may increase stress on the server I/O subsystem and increase competition for cache resources.
  • If the current number of databases in the cache is greater than or equal to the maximum allowed times 1.5, when a database is closed, Domino doesn't put the database in the cache. Instead it uses the slower, non-cache method to close the database. And when a user or process next opens the database, Domino reads the database from disk rather than from the cache, causing the database to open more slowly than if it were in the cache.