diff --git a/tests/scripts/test063-delta-multiprovider b/tests/scripts/test063-delta-multiprovider index 32ab7bdc43..668ce94660 100755 --- a/tests/scripts/test063-delta-multiprovider +++ b/tests/scripts/test063-delta-multiprovider @@ -25,7 +25,7 @@ if test $ACCESSLOG = accesslogno; then exit 0 fi -MPR=2 +MPR=${MPR-4} XDIR=$TESTDIR/srv TMP=$TESTDIR/tmp @@ -76,15 +76,21 @@ CFDIR=${XDIR}$n/slapd.d mkdir -p ${XDIR}$n $DBDIR.1 $DBDIR.2 $CFDIR -o=`expr 3 - $n` cat > $TMP <> $TMP +o=`expr $o + 1` +done +echo "" >> $TMP + if [ "$SYNCPROV" = syncprovmod -o "$ACCESSLOG" = accesslogmod ]; then cat <> $TMP dn: cn=module,cn=config @@ -175,11 +181,23 @@ olcSuffix: $BASEDN ${nullExclude}olcDbDirectory: ${DBDIR}.2 olcRootDN: $MANAGERDN olcRootPW: $PASSWD -olcSyncRepl: rid=001 provider=$PROVIDERURI binddn="$MANAGERDN" bindmethod=simple +EOF + +o=1 +while [ $o -le $MPR ]; do +PORT=`expr $BASEPORT + $o` +URI="ldap://${LOCALHOST}:$PORT/" +cat >>$TMP <> $TMP < /dev/null 2>&1 @@ -364,22 +383,14 @@ done echo "Breaking replication between server 1 and 2..." n=1 -while [ $n -le $MPR ]; do -o=`expr 3 - $n` +while [ $n -le 2 ]; do MYURI=`eval echo '$URI'$n` -PROVIDERURI=`eval echo '$URI'$o` +o=`expr $n - 1` $LDAPMODIFY -D cn=config -H $MYURI -y $CONFIGPWF > $TESTOUT 2>&1 < $TESTOUT 2>&1 < $TMP <> $TMP <> $TMP < $TESTOUT 2>&1 <$TMP RC=$? if test $RC != 0 ; then echo "ldapmodify failed for server $n config ($RC)!"