[Date Prev][Date Next]
Re: Restoring with SLAPADD
Michael Ströder wrote:
Dave Horsfall wrote:
Delete an entry. Oops, I need it back. Stop the master (and slave), "rm
*.bdb __*", "slapadd -nX< slap.out", start the master and slave, check
the slave, and the deleted entry has reappeared.
If you need back a single entry or just a few entries I'd rather
try to extract them from slapcat-generated LDIF, remove the
entryCSN attributes and slapadd them, not the whole database. From
my understanding new entryCSN would be generated and the
contextCSN would be increased. Howard, is this correct?
Yes, a new entryCSN would be generated if you remove the old one. And yes, if
you use slapadd -w the contextCSN will be updated as well.
Still I'd use slapadd if you can accept the down-time needed
instead of normal ldapadd since the entryUUID and other
operational attributes are preserved which can be a real
requirement in case some other data syncing is based on that.
(Using ldapadd with Relax Rules Control formerly known as Manage
DIT control would be another option to restore the entry with the
-- Howard Chu
Chief Architect, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/