Ticket #47463 - IDL-style can become mismatched during partial restoration
The commit to 389-ds-base-1.3.2 and newer is back ported to 389-ds-
1.2.11 trough 1.3.1 by Thomas E Lackey.
commit b43145218dccc8c9c16ecadad80f94bf58c73d57
Author: Noriko Hosoi <nhosoi@redhat.com>
Date: Fri Sep 27 17:58:03 2013 -0700
Description by telackey:
When doing a partial/FRI restoration the database files are copied
key-by-key. This is necessary to reset the LSNs so the restored
files can merge into the existing DB environment (cf. dblayer_copy_
file_resetlsns()) in a recoverable way.
However, dblayer_copy_file_keybykey() does not set the comparison
function before calling DB->put(), which means that the restored
files will not necessarily be using the proper function.
While all the keys are technically present, indexed searches can
still fail to return relevant results because the key order is
significant when intersecting the results with the other indices.
Note: The bug was reported and the patch was provided by telackey.
(Thank you, Thomas!)
Additional fix by nhosoi:
The entryrdn index uses its special dup compare function. The dup
compare function is set when the restoring index file is entryrdn.
https://fedorahosted.org/389/ticket/47463
Reviewed by rmeggins (Thank you, Rich!)