Shared memory for Ldap 5.x

Revision as of 11:56, 9 July 2012 by Santosh rao99 (talk | contribs) (Created page with "To setup SHM keys : 1. Calculate and set kernel.shmall and kernel.shmmax (you already have detailed steps for this from the wiki) 2. ldap stop 3. /opt/zimbra/sleepycat/bin/db_r...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

To setup SHM keys :

1. Calculate and set kernel.shmall and kernel.shmmax (you already have detailed steps for this from the wiki) 2. ldap stop 3. /opt/zimbra/sleepycat/bin/db_recover -c -h /opt/zimbra/openldap-data/

  This is being done to clear current MMAP files, so that if and when you roll back you have a clean slate.

3.5 Confirm whether "/opt/zimbra/openldap-data" and __db.* is deleted. 4. Set the shared memory keys in /opt/zimbra/conf/slapd.conf.in

  1. shmkey

shm_key 5 5. Start ldap. 6. Verify if memory keys are being used: ipcs -mp (the column CPID is the process ID which is using the shared memory referenced by the key which was set up in step 6)

Only change in the above from before, is the addition of db_recover before setting the shm keys. This is to ensure we delete the cache files before changing the config.


To Roll back to MMAP :

1. ldap stop 2. /opt/zimbra/sleepycat/bin/db_recover -c -h

/opt/zimbra/openldap-data/  (this should delete the bdb cache files)

3. ipcrm [ -M key or -m id ] (to delete files from memory, at this point rebooting should also clear the memory files)******

      Skip this if the file has already been removed, but please confirm using ipcs -m or ipcs -mp to check if the memory keys have been removed. If not then user ipcrm to manually delete the shm keys

4. update config to comment/remove shm keys configuration 5. start ldap (this should now be using the MMAP files)

Jump to: navigation, search