Added optional 3rd parameter, to make the script display the slapd pid

and wait. User must hit <NewLine> to continue. This gives the opportunity
to attach a debugger to the slapd before proceeding with the test.
This commit is contained in:
Howard Chu 2001-09-22 05:34:22 +00:00
parent 00a28378f8
commit 4eaad48247
11 changed files with 99 additions and 0 deletions

View File

@ -10,6 +10,11 @@ if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -23,6 +28,10 @@ echo "Starting slapd on TCP/IP port $PORT..."
. $CONFFILTER $BACKEND < $SCHEMACONF > $DBCONF
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Using ldapsearch to retrieve all the entries..."
for i in 0 1 2 3 4 5; do

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -32,6 +36,10 @@ echo "Starting slapd on TCP/IP port $PORT..."
. $CONFFILTER $BACKEND < $CONF > $DBCONF
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Using ldapsearch to retrieve all the entries..."
for i in 0 1 2 3 4 5; do
@ -59,6 +67,8 @@ $CMP $SEARCHFLT $LDIFFLT > $CMPOUT
if test $? != 0 ; then
echo "comparison failed - database was not created correctly"
echo $SEARCHFLT $LDIFFLT
diff -u $SEARCHFLT $LDIFFLT
exit 1
fi

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -21,6 +25,10 @@ echo "Starting slapd on TCP/IP port $PORT..."
. $CONFFILTER $BACKEND < $CONF > $DBCONF
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Using ldapsearch to check that slapd is running..."
for i in 0 1 2 3 4 5; do

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -38,6 +42,10 @@ fi
echo "Starting slapd on TCP/IP port $PORT..."
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Testing slapd searching..."
for i in 0 1 2 3 4 5; do

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -32,6 +36,10 @@ fi
echo "Starting slapd on TCP/IP port $PORT..."
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Testing slapd modify operations..."
for i in 0 1 2 3 4 5; do

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -29,6 +33,10 @@ fi
echo "Starting slapd on TCP/IP port $PORT..."
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Testing slapd modrdn operations..."
# Make sure we can search the database

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -29,6 +33,10 @@ fi
echo "Starting slapd on TCP/IP port $PORT..."
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Testing slapd access control..."
for i in 0 1 2 3 4 5; do

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -38,11 +42,19 @@ echo "Starting master slapd on TCP/IP port $PORT..."
. $CONFFILTER $BACKEND < $MASTERCONF > $DBCONF
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Starting slave slapd on TCP/IP port $SLAVEPORT..."
. $CONFFILTER $BACKEND < $SLAVECONF > $REPLCONF
$SLAPD -f $REPLCONF -h $SLAVEURI -d $LVL $TIMING > $SLAVELOG 2>&1 &
SLAVEPID=$!
if test $WAIT != 0 ; then
echo SLAVEPID $SLAVEPID
read foo
fi
echo "Using ldapsearch to check that master slapd is running..."
for i in 0 1 2 3 4 5; do

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -34,6 +38,10 @@ sleep 5
echo "Starting slapd on TCP/IP port $PORT..."
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Using ldapsearch to check that slapd is running..."
for i in 0 1 2 3 4 5; do

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -35,11 +39,19 @@ fi
echo "Starting master slapd on TCP/IP port $PORT..."
$SLAPD -n master -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Starting slave slapd on TCP/IP port $SLAVEPORT..."
. $CONFFILTER $BACKEND < $REFSLAVECONF > $REPLCONF
$SLAPD -n slave -f $REPLCONF -h $SLAVEURI -d $LVL $TIMING > $SLAVELOG 2>&1 &
SLAVEPID=$!
if test $WAIT != 0 ; then
echo SLAVEPID $SLAVEPID
read foo
fi
echo "Testing for master slapd..."
for i in 0 1 2 3 4 5; do

View File

@ -9,6 +9,10 @@ BACKEND=ldbm
if test $# -ge 1 ; then
BACKEND=$1; shift
fi
WAIT=0
if test $# -ge 1 ; then
WAIT=1; shift
fi
echo "running defines.sh"
. $SRCDIR/scripts/defines.sh
@ -21,6 +25,10 @@ echo "Starting slapd on TCP/IP port $PORT..."
. $CONFFILTER $BACKEND < $PWCONF > $DBCONF
$SLAPD -f $DBCONF -h $MASTERURI -d $LVL $TIMING > $MASTERLOG 2>&1 &
PID=$!
if test $WAIT != 0 ; then
echo PID $PID
read foo
fi
echo "Using ldapsearch to check that slapd is running..."
for i in 0 1 2 3 4 5; do