exit $RC
fi
-echo "Waiting 15 seconds for syncrepl to receive changes..."
-sleep 15
+SLEEP=15
+echo "Waiting $SLEEP seconds for syncrepl to receive changes..."
+sleep $SLEEP
# first check
#echo "Using ldapsearch to read all the entries from the master..."
exit 1
fi
-echo "Stopping the provider, sleeping 10 seconds and restarting it..."
+SLEEP=10
+echo "Stopping the provider, sleeping $SLEEP seconds and restarting it..."
kill -HUP "$MASTERPID"
-sleep 10
-echo "RESTART" >> $LOG1
+sleep $SLEEP
+
+echo "======================= RESTART =======================" >> $LOG1
$SLAPD -f $CONF1 -h $URI1 -d $LVL $TIMING >> $LOG1 2>&1 &
MASTERPID=$!
if test $WAIT != 0 ; then
exit $RC
fi
-echo "Waiting 15 seconds for syncrepl to receive changes..."
-sleep 15
+SLEEP=15
+echo "Waiting $SLEEP seconds for syncrepl to receive changes..."
+sleep $SLEEP
# second check
#echo "Using ldapsearch to read all the entries from the master..."
exit 1
fi
-echo "Stopping proxy to test recovery..."
+SLEEP=10
+echo "Stopping proxy to test recovery; sleep for $SLEEP seconds..."
kill -HUP $PROXYPID
-sleep 10
+sleep $SLEEP
echo "Modifying more entries on the master..."
$LDAPMODIFY -v -D "$MANAGERDN" -h $LOCALHOST -p $PORT1 -w $PASSWD >> \
EOMODS
echo "Restarting proxy..."
-echo "RESTART" >> $LOG3
+echo "======================= RESTART =======================" >> $LOG3
$SLAPD -f $CONF3 -h $URI3 -d $LVL $TIMING >> $LOG3 2>&1 &
PROXYPID=$!
if test $WAIT != 0 ; then
fi
KILLPIDS="$MASTERPID $SLAVEPID $PROXYPID"
-echo "Waiting 25 seconds for syncrepl to receive changes..."
-sleep 25
+SLEEP=25
+echo "Waiting $SLEEP seconds for syncrepl to receive changes..."
+sleep $SLEEP
# third check
#echo "Using ldapsearch to read all the entries from the master..."
exit $RC
fi
- echo "Waiting 15 seconds for syncrepl to receive changes..."
- sleep 15
+ SLEEP=15
+ echo "Waiting $SLEEP seconds for syncrepl to receive changes..."
+ sleep $SLEEP
fi
# fourth check
exit 1
fi
-echo "Stopping consumer to test recovery..."
+SLEEP=10
+echo "Stopping consumer to test recovery; wait $SLEEP seconds..."
kill -HUP $SLAVEPID
-sleep 10
+sleep $SLEEP
echo "Modifying more entries on the master..."
$LDAPMODIFY -v -D "$MANAGERDN" -h $LOCALHOST -p $PORT1 -w $PASSWD >> \
EOMODS
echo "Restarting consumer..."
-echo "RESTART" >> $LOG2
+echo "======================= RESTART =======================" >> $LOG2
$SLAPD -f $CONF2 -h $URI2 -d $LVL $TIMING >> $LOG2 2>&1 &
SLAVEPID=$!
if test $WAIT != 0 ; then
fi
KILLPIDS="$MASTERPID $SLAVEPID $PROXYPID"
-echo "Waiting 25 seconds for syncrepl to receive changes..."
-sleep 25
+SLEEP=25
+echo "Waiting $SLEEP seconds for syncrepl to receive changes..."
+sleep $SLEEP
# fifth check
#echo "Using ldapsearch to read all the entries from the master..."
exit $RC
fi
-echo "Waiting 15 seconds for syncrepl to receive changes..."
-sleep 15
+SLEEP=15
+echo "Waiting $SLEEP seconds for syncrepl to receive changes..."
+sleep $SLEEP
# sixth check
#echo "Using ldapsearch to read all the entries from the master..."