#51261 Ticket 51260 - fix potential syncrepl data corruption
Closed by spichugi. Opened by firstyear.
firstyear/389-ds-base 51171-entryuuid-syncrepl  into  master

Download 51261.patch

Bug Description: The cookie encodes which changelog entries we
have seen up to and including. However, the sync process would then
re-send the cl item from the cookie number. This could cause corruption
in some cases as some combinations of actions between two points
are no-oped in the server.

Fix Description: Fix the changelog search to always process that
entries of the CL must be greater than, but not equal to the
already seen CL items from the cookie.
fixes #51260
https://pagure.io/389-ds-base/issue/51260
Author: William Brown <william@blackhats.net.au>

NOTE: This is split into two commits. One which is supplementary improvements such as test and documentation expansion around sync repl. The second is the fix to the issue, which is isolated to allow easier backporting.

2 new commits added

  • Ticket 51260 - improve tests and improve readme re refdel
  • Ticket 51260 - fix potential syncrepl data corruption

I agree with that change. My understanding is that starting client_cookie+1 conforms RFC

In each phase, for each entry or reference that has been added to the
content or been changed since the previous Sync Operation indicated
by the cookie, the server returns a SearchResultEntry or
SearchResultReference Message, ....

You may add this in your comment

'chg_count' should be server_cookie - client_cookie.
In case chg_count == 0 then the routine would exit immediately (saving internal search and lot of computation)

The fix looks good to me. Let's wait feedback from @elkris and others.

Yep. I'd also want @mreynolds to comment if we should backport this fix to older versions too since I think this would affect many versions ....

Pull-Request has been closed by spichugi

Pull-Request has been reopened by spichugi

Pull-Request has been closed by spichugi

Pull-Request has been closed by spichugi

Pull-Request has been closed by spichugi

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This pull request has been cloned to Github as issue and is available here:
- https://github.com/389ds/389-ds-base/issues/4314

If you want to continue to work on the PR, please navigate to the github issue,
download the patch from the attachments and file a new pull request.

Thank you for understanding. We apologize for all inconvenience.

Pull-Request has been closed by spichugi

Metadata