summaryrefslogtreecommitdiff
path: root/source4/script/tests
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2006-09-28 17:08:17 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:20:26 -0500
commit736e797983d8fa5bd7467a1d47bd137290abb478 (patch)
tree6c2d7542433de6c3ea0c317bbf35ae61d8a90894 /source4/script/tests
parentc2a2c2456d807784bdacb9e088044a85fe278315 (diff)
downloadsamba-736e797983d8fa5bd7467a1d47bd137290abb478.tar.gz
samba-736e797983d8fa5bd7467a1d47bd137290abb478.tar.bz2
samba-736e797983d8fa5bd7467a1d47bd137290abb478.zip
r18979: With these extra indexes (also added for the normal case) and a
DB_CONFIG file, we now get reasonable enought performance to pass 'make test' against OpenLDAP. We do have to double the maximum runtime for the torture client however. Andrew Bartlett (This used to be commit 5b3c8cc036c1180c9e96d9aaacd3f2e0a83460e5)
Diffstat (limited to 'source4/script/tests')
-rwxr-xr-xsource4/script/tests/mktestsetup.sh33
-rwxr-xr-xsource4/script/tests/selftest.sh2
2 files changed, 33 insertions, 2 deletions
diff --git a/source4/script/tests/mktestsetup.sh b/source4/script/tests/mktestsetup.sh
index b1db8d2494..2d3422efc5 100755
--- a/source4/script/tests/mktestsetup.sh
+++ b/source4/script/tests/mktestsetup.sh
@@ -71,7 +71,7 @@ export SERVER
export NETBIOSNAME
rm -rf $PREFIX/*
-mkdir -p $PRIVATEDIR $ETCDIR $PIDDIR $NCALRPCDIR $LOCKDIR $TMPDIR $TLSDIR $LDAPDIR/db
+mkdir -p $PRIVATEDIR $ETCDIR $PIDDIR $NCALRPCDIR $LOCKDIR $TMPDIR $TLSDIR $LDAPDIR/db $LDAPDIR/db/bdb-logs $LDAPDIR/db/tmp
if [ -z "$VALGRIND" ]; then
nativeiconv="true"
@@ -339,9 +339,11 @@ index uidNumber eq
index gidNumber eq
index unixName eq
index privilege eq
-index nCName eq
+index nCName eq pres
index lDAPDisplayName eq
index subClassOf eq
+index dnsRoot eq
+index nETBIOSName eq pres
overlay syncprov
syncprov-checkpoint 100 10
@@ -349,6 +351,33 @@ syncprov-sessionlog 100
EOF
+cat > $LDAPDIR/db/DB_CONFIG <<EOF
+#
+ # Set the database in memory cache size.
+ #
+ set_cachesize 0 524288 0
+
+
+ #
+ # Set database flags (this is a test environment, we don't need to fsync()).
+ #
+ set_flags DB_TXN_NOSYNC
+
+ #
+ # Set log values.
+ #
+ set_lg_regionmax 104857
+ set_lg_max 1048576
+ set_lg_bsize 209715
+ set_lg_dir $LDAPDIR/db/bdb-logs
+
+
+ #
+ # Set temporary file creation directory.
+ #
+ set_tmp_dir $LDAPDIR/db/tmp
+EOF
+
PROVISION_OPTIONS="$CONFIGURATION --host-name=$NETBIOSNAME --host-ip=127.0.0.1"
PROVISION_OPTIONS="$PROVISION_OPTIONS --quiet --domain $DOMAIN --realm $REALM"
PROVISION_OPTIONS="$PROVISION_OPTIONS --adminpass $PASSWORD --root=$ROOT"
diff --git a/source4/script/tests/selftest.sh b/source4/script/tests/selftest.sh
index 9828e62d88..48db3eccf2 100755
--- a/source4/script/tests/selftest.sh
+++ b/source4/script/tests/selftest.sh
@@ -69,6 +69,8 @@ if [ x"$TEST_LDAP" = x"yes" ]; then
echo "LDAP PROVISIONING failed: $srcdir/bin/smbscript $srcdir/setup/provision $PROVISION_OPTIONS --ldap-backend=$LDAPI"
exit 1;
}
+ #LDAP is slow
+ TORTURE_MAXTIME=`expr $TORTURE_MAXTIME '*' 2`
fi
SMBD_TEST_FIFO="$PREFIX/smbd_test.fifo"