[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
Not deleted in Syncrepl
- To: openldap-technical@openldap.org
- Subject: Not deleted in Syncrepl
- From: s_hira@nifty.com
- Date: Wed, 28 Mar 2012 14:47:54 +0900 (JST)
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=apr2010web; t=1332913674; bh=Cu3QVTDDwfo7VfKKpWC1+8zNUN23Y1FhcDpGKwNptWc=; h=Message-ID:Date:From:To:Subject:MIME-Version:Content-Type: Content-Transfer-Encoding; b=yeNLs8ka1ObZtmWcQbLbmEXNCPZudCKLk6YDTvoIMnOvqy7VcniyIyaxLJtppuyLk /bEY0cNKsWMjQSmV3sELgLEuMXeyM1NGC1EJEVBNI5riNtl4JP8Pv6AtSvLmVIO64e sOffyGVARLSPSUulrPYH0C5dsAV2IIOtmhISN15U=
Hi, All
I confirmed the problem that was not deleted in syncrepl of V2.4.30.
The provider operates it in "syncprov-sessionlog 100".
After I delete 150 in a provider, and going syncrepl
Only 100 cases are deleted in the consumer side.
After examining it, the following parts seem to have a problem.
servers/slapd/overlays/syncprov.c:2638
if ( sl->sl_num > 0 ) {
int i;
for ( i=0; i<sl->sl_numcsns; i++ ) {
/* SID not present == new enough */
if ( minsid < sl->sl_sids[i] ) {
do_play = 1;
break;
}
/* SID present and new enough */
if ( minsid == sl->sl_sids[i]
&& ber_bvcmp( &mincsn, &sl->sl_mincsn[i] ) >= 0 ) {
do_play = 1;
break;
}
}
/* SID not present == new enough */
if ( i == sl->sl_numcsns )
do_play = 1;
}
if ( do_play ) {
do_present = 0;
/* mutex is unlocked in playlog */
syncprov_playlog( op, rs, sl, srs, ctxcsn, numcsns, sids );
} else {
ldap_pvt_thread_mutex_unlock( &sl->sl_mutex );
}
Then, it corrected as follows.
===
- if ( minsid == sl->sl_sids[i]
- && ber_bvcmp( &mincsn, &sl->sl_mincsn[i] ) >= 0 ) {
+ if ( minsid == sl->sl_sids[i] ) {
+ if ( ber_bvcmp( &mincsn, &sl->sl_mincsn[i] ) >= 0 ) {
do_play = 1;
+ }
break;
}
Is this correction wrong?
HIRABAYASHI Satoshi
s_hira@nifty.com