My Oracle Support Banner

OUD 11g/12c - How to Restore Data without Replaying Replication Changes (Doc ID 2715482.1)

Last updated on MAY 31, 2023

Applies to:

Oracle Unified Directory - Version 12.2.1.3.180829 and later
Information in this document applies to any platform.

Goal

In this scenario, a series of unwanted changes to data occurred that need to be backed out.

A backup was made prior to the change of data, but following an attempt to restore the backup the unwanted changes stored in the replication changelog get replayed against the restored data.

- Backup instance
$ ./backup --backUpAll --compress --backupDirectory <BACKUP_DIR>

 - Example modification following backup
$ ldapmodify -p <PORT> -D cn=<DM> -j ~/<PASSWORD_FILE>
dn: <UID>,ou=People,<SUFFIX>
changetype: modify
replace: displayname
displayname: bad change
Processing MODIFY request for <UID>,ou=People,<SUFFIX>
MODIFY operation successful for DN <UID>,ou=People,<SUFFIX>

 - Confirm modification on primary and secondary replica
$ ldapsearch -p <PORT> -D cn=<DM> -j ~/<PASSWORD_FILE> -b <SUFFIX> <UID> displayname
dn: <UID>,ou=People,<SUFFIX>
displayname: bad change

$ ldapsearch -p <REPLICA_PORT> -D cn=<DM> -j ~/<PASSWORD_FILE> -b <SUFFIX> <UID> displayname
dn: <UID>,ou=People,<SUFFIX>
displayname: bad change

 - Restore data
$ ./restore --backupDirectory <BACKUP_DIR>
[04/Sep/2020:16:54:51 +0000] category=JEB severity=NOTICE msgID=8847445 msg=Restored: 00000000.jdb (size 99999977)
[04/Sep/2020:16:54:51 +0000] category=JEB severity=NOTICE msgID=8847445 msg=Restored: 00000001.jdb (size 51368651)

 - Start DS
$ ./start-ds

 - Replication changelog replayed previous modification of bad data.
$ ldapsearch -p <PORT> -D cn=<DM> -j ~/<PASSWORD_FILE> -b <SUFFIX> <UID> displayname
dn: <UID>,ou=People,<SUFFIX>
displayname: bad change
 

Solution

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Goal
Solution


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.