Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Joe Martin
OpenLDAP
Commits
947f2cd6
Commit
947f2cd6
authored
Dec 06, 2009
by
Hallvard Furuseth
Browse files
Support back-null after all
parent
13818250
Changes
6
Hide whitespace changes
Inline
Side-by-side
tests/scripts/test049-sync-config
View file @
947f2cd6
...
...
@@ -21,11 +21,6 @@ if test $SYNCPROV = syncprovno; then
exit
0
fi
if
test
$BACKEND
=
null
;
then
echo
"
$BACKEND
backend does not support cn=config, test skipped"
exit
0
fi
PRODIR
=
$TESTDIR
/pro
CONDIR
=
$TESTDIR
/con1
DBPRO
=
$PRODIR
/db
...
...
@@ -224,6 +219,9 @@ if test $RC != 0 ; then
exit
$RC
fi
nullExclude
=
""
nullOK
=
""
test
$BACKEND
=
null
&&
nullExclude
=
"# "
nullOK
=
"OK"
if
[
"
$BACKENDTYPE
"
=
mod
]
;
then
$LDAPADD
-D
cn
=
config
-H
$URI1
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: cn=module,cn=config
...
...
@@ -243,10 +241,10 @@ fi
$LDAPADD
-D
cn
=
config
-H
$URI1
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcSuffix:
$BASEDN
olcDbDirectory: ./db
${
nullExclude
}
olcDbDirectory: ./db
olcRootDN:
$MANAGERDN
olcRootPW:
$PASSWD
olcSyncRepl: rid=002 provider=
$URI1
binddn="
$MANAGERDN
" bindmethod=simple
...
...
@@ -304,7 +302,7 @@ for i in 0 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI2
\
-s
base
-b
"cn=Ursula Hampster,ou=Alumni Association,ou=People,dc=example,dc=com"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
tests/scripts/test050-syncrepl-multimaster
View file @
947f2cd6
...
...
@@ -21,11 +21,6 @@ if test $SYNCPROV = syncprovno; then
exit
0
fi
if
test
$BACKEND
=
null
;
then
echo
"
$BACKEND
backend does not support cn=config, test skipped"
exit
0
fi
MMR
=
${
MMR
-4
}
if
[
$MMR
-gt
9
]
;
then
...
...
@@ -263,6 +258,9 @@ if test $RC != 0 ; then
exit
$RC
fi
nullExclude
=
""
test
$BACKEND
=
null
&&
nullExclude
=
"# "
echo
""
>
$TMP
if
[
"
$BACKENDTYPE
"
=
mod
]
;
then
cat
<<
EOF
>>
$TMP
...
...
@@ -278,10 +276,10 @@ fi
cat
<<
EOF
>>
$TMP
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcSuffix:
$BASEDN
olcDbDirectory: ./db
${
nullExclude
}
olcDbDirectory: ./db
olcRootDN:
$MANAGERDN
olcRootPW:
$PASSWD
EOF
...
...
tests/scripts/test052-memberof
View file @
947f2cd6
...
...
@@ -21,11 +21,6 @@ if test $MEMBEROF = memberofno; then
exit
0
fi
if
test
$BACKEND
=
null
;
then
echo
"
$BACKEND
backend does not support cn=config, test skipped"
exit
0
fi
mkdir
-p
$TESTDIR
$DBDIR1
$TESTDIR
/confdir
$SLAPPASSWD
-g
-n
>
$CONFIGPWF
...
...
@@ -77,14 +72,10 @@ EOF
fi
fi
bdb_conf
=
""
case
$BACKEND
in
bdb
|
hdb
)
bdb_conf
=
"olcDbCacheSize: 1000
olcDbIndex: objectClass eq
olcDbIndex: cn pres,eq,sub
olcDbIndex: uid pres,eq,sub
olcDbIndex: sn pres,eq,sub
olcDbMode: 384"
bdbInclude
=
"# "
nullExclude
=
""
case
$BACKEND
in
bdb
|
hdb
)
bdbInclude
=
""
;;
null
)
nullExclude
=
"# "
;;
esac
echo
"Running ldapadd to build slapd config database..."
...
...
@@ -112,14 +103,19 @@ olcObjectClasses: ( 1.3.6.1.4.1.4754.31.2.4
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcSuffix:
$BASEDN
olcRootDN: cn=Manager,
$BASEDN
olcRootPW:: c2VjcmV0
olcMonitoring: TRUE
olcDbDirectory:
$TESTDIR
/db.1.a/
$bdb_conf
${
nullExclude
}
olcDbDirectory:
$TESTDIR
/db.1.a/
${
bdbInclude
}
olcDbCacheSize: 1000
${
bdbInclude
}
olcDbIndex: objectClass eq
${
bdbInclude
}
olcDbIndex: cn pres,eq,sub
${
bdbInclude
}
olcDbIndex: uid pres,eq,sub
${
bdbInclude
}
olcDbIndex: sn pres,eq,sub
${
bdbInclude
}
olcDbMode: 384"
dn: olcOverlay={0}memberof,olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcOverlayConfig
...
...
tests/scripts/test053-syncprov-glue
View file @
947f2cd6
...
...
@@ -27,11 +27,6 @@ if test $SYNCPROV = syncprovno; then
exit
0
fi
if
test
$BACKEND
=
null
;
then
echo
"
$BACKEND
backend does not support cn=config, test skipped"
exit
0
fi
PRODDIR
=
$TESTDIR
/prod
PRO2DIR
=
$TESTDIR
/pro2
CONSDIR
=
$TESTDIR
/cons
...
...
@@ -244,12 +239,15 @@ EOF
fi
fi
nullExclude
=
""
nullOK
=
""
test
$BACKEND
=
null
&&
nullExclude
=
"# "
nullOK
=
"OK"
$LDAPADD
-D
cn
=
config
-H
$URI1
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$PRODDIR
/db
${
nullExclude
}
olcDbDirectory:
$PRODDIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$MANAGERDN
olcRootPW:
$PASSWD
...
...
@@ -274,9 +272,9 @@ olcOverlay: {1}syncprov
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$PRODDIR
/ou1
${
nullExclude
}
olcDbDirectory:
$PRODDIR
/ou1
olcSubordinate: TRUE
olcSuffix: ou=ou1,
$BASEDN
olcRootDN:
$MANAGERDN
...
...
@@ -310,9 +308,9 @@ fi
$LDAPADD
-D
cn
=
config
-H
$URI2
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$PRO2DIR
/db
${
nullExclude
}
olcDbDirectory:
$PRO2DIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$MANAGERDN
olcRootPW:
$PASSWD
...
...
@@ -334,9 +332,9 @@ echo "Adding databases on consumer..."
$LDAPADD
-D
cn
=
config
-H
$URI3
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$CONSDIR
/db
${
nullExclude
}
olcDbDirectory:
$CONSDIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$MANAGERDN
...
...
@@ -432,7 +430,7 @@ for i in 0 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI3
\
-s
base
-b
"ou=ou1,
$BASEDN
"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -468,7 +466,7 @@ for i in 0 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI3
\
-s
base
-b
"ou=ou1,
$BASEDN
"
\
'(description=Modify1)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -481,6 +479,7 @@ if test $RC != 0 ; then
exit
$RC
fi
case
$BACKEND
in
bdb
|
hdb
)
db_stat
=
for
path
in
`
echo
"
$PATH
"
|
sed
-e
's/:/ /g'
`
;
do
if
test
-f
"
$path
/db_stat"
&&
\
...
...
@@ -501,6 +500,7 @@ else
echo
"Glue lock bug not found :-)"
lock_bug
=
0
fi
esac
echo
"Using ldapmodify to modify glue suffix on producer..."
$LDAPADD
-D
"
$MANAGERDN
"
-H
$URI1
-w
$PASSWD
<<
EOF
>>
$TESTOUT
2>&1
...
...
tests/scripts/test057-memberof-refint
View file @
947f2cd6
...
...
@@ -27,11 +27,10 @@ if test $REFINT = refintno; then
exit
0
fi
case
$BACKEND
in
bdb
|
null
)
# BDB lacks subtree rename, NULL lacks cn=config support
echo
"Test does not support
$BACKEND
, test skipped"
if
test
$BACKEND
=
bdb
;
then
echo
"
$BACKEND
backend does not support subtree rename, test skipped"
exit
0
esac
fi
mkdir
-p
$TESTDIR
$DBDIR1
$TESTDIR
/confdir
...
...
@@ -67,6 +66,12 @@ fi
cat
/dev/null
>
$TESTOUT
bdbInclude
=
"# "
nullExclude
=
""
case
$BACKEND
in
bdb
|
hdb
)
bdbInclude
=
""
;;
null
)
nullExclude
=
"# "
;;
esac
if
[
"
$MEMBEROF
"
=
memberofmod
]
;
then
echo
"Inserting memberof overlay on producer..."
$LDAPADD
-D
cn
=
config
-H
$URI1
-y
$CONFIGPWF
<<
EOF
>
$TESTOUT
2>&1
...
...
@@ -85,29 +90,24 @@ EOF
fi
fi
bdb_conf
=
""
case
$BACKEND
in
bdb
|
hdb
)
bdb_conf
=
"olcDbCacheSize: 1000
olcDbIndex: objectClass eq
olcDbIndex: cn pres,eq,sub
olcDbIndex: uid pres,eq,sub
olcDbIndex: sn pres,eq,sub
olcDbMode: 384"
esac
echo
"Running ldapadd to build slapd config database..."
$LDAPADD
-h
$LOCALHOST
-p
$PORT1
-D
'cn=config'
-w
`
cat
$CONFIGPWF
`
\
>>
$TESTOUT
2>&1
<<
EOF
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcSuffix:
$BASEDN
olcRootDN: cn=Manager,
$BASEDN
olcRootPW:: c2VjcmV0
olcMonitoring: TRUE
olcDbDirectory:
$TESTDIR
/db.1.a/
$bdb_conf
${
nullExclude
}
olcDbDirectory:
$TESTDIR
/db.1.a/
${
bdbInclude
}
olcDbCacheSize: 1000
${
bdbInclude
}
olcDbIndex: objectClass eq
${
bdbInclude
}
olcDbIndex: cn pres,eq,sub
${
bdbInclude
}
olcDbIndex: uid pres,eq,sub
${
bdbInclude
}
olcDbIndex: sn pres,eq,sub
${
bdbInclude
}
olcDbMode: 384
# {0}memberof, {1}
$BACKEND
, config
dn: olcOverlay={0}memberof,olcDatabase={1}
$BACKEND
,cn=config
...
...
tests/scripts/test058-syncrepl-asymmetric
View file @
947f2cd6
...
...
@@ -111,11 +111,10 @@
# environment variable RACE_TESTS can be set to the number of race test
# iterations the script should perform.
case
"
$BACKEND
"
in
ldif
|
null
)
# LDIF lacks ACL support, NULL lacks cn=config support
echo
"This test does not support the
$BACKEND
backend"
exit
0
;;
esac
if
test
"
$BACKEND
"
=
ldif
;
then
echo
"
$backend
backend does not support access controls, test skipped"
exit
0
fi
echo
"running defines.sh"
.
$SRCDIR
/scripts/defines.sh
...
...
@@ -403,12 +402,15 @@ EOF
fi
fi
nullExclude
=
""
nullOK
=
""
wantNoObj
=
32
test
$BACKEND
=
null
&&
nullExclude
=
"# "
nullOK
=
"OK"
wantNoObj
=
0
$LDAPADD
-D
cn
=
config
-H
$URI1
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SMC_DIR
/db
${
nullExclude
}
olcDbDirectory:
$SMC_DIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$MANAGERDN
olcRootPW:
$PASSWD
...
...
@@ -425,45 +427,45 @@ olcSpCheckpoint: 3 1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SMC_DIR
/ou1
${
nullExclude
}
olcDbDirectory:
$SMC_DIR
/ou1
olcSubordinate: TRUE
olcSuffix: ou=ou1,
$BASEDN
olcRootDN:
$MANAGERDN
dn: olcDatabase={2}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {2}
$BACKEND
olcDbDirectory:
$SMC_DIR
/ou2
${
nullExclude
}
olcDbDirectory:
$SMC_DIR
/ou2
olcSubordinate: TRUE
olcSuffix: ou=ou2,
$BASEDN
olcRootDN:
$MANAGERDN
dn: olcDatabase={3}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {3}
$BACKEND
olcDbDirectory:
$SMC_DIR
/sm1ou1
${
nullExclude
}
olcDbDirectory:
$SMC_DIR
/sm1ou1
olcSubordinate: TRUE
olcSuffix: ou=sm1ou1,
$BASEDN
olcRootDN:
$UPDATEDN
dn: olcDatabase={4}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {4}
$BACKEND
olcDbDirectory:
$SMC_DIR
/sm1ou2
${
nullExclude
}
olcDbDirectory:
$SMC_DIR
/sm1ou2
olcSubordinate: TRUE
olcSuffix: ou=sm1ou2,
$BASEDN
olcRootDN:
$UPDATEDN
dn: olcDatabase={5}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {5}
$BACKEND
olcDbDirectory:
$SMC_DIR
/sm2ou1
${
nullExclude
}
olcDbDirectory:
$SMC_DIR
/sm2ou1
olcSubordinate: TRUE
olcSuffix: ou=sm2ou1,
$BASEDN
olcRootDN:
$UPDATEDN
...
...
@@ -497,9 +499,9 @@ fi
$LDAPADD
-D
cn
=
config
-H
$URI2
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SM1_DIR
/db
${
nullExclude
}
olcDbDirectory:
$SM1_DIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$UPDATEDN
...
...
@@ -514,18 +516,18 @@ olcOverlay: {1}syncprov
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SM1_DIR
/ou1
${
nullExclude
}
olcDbDirectory:
$SM1_DIR
/ou1
olcSubordinate: TRUE
olcSuffix: ou=ou1,
$BASEDN
olcRootDN:
$UPDATEDN
dn: olcDatabase={2}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {2}
$BACKEND
olcDbDirectory:
$SM1_DIR
/sm1ou1
${
nullExclude
}
olcDbDirectory:
$SM1_DIR
/sm1ou1
olcSubordinate: TRUE
olcSuffix: ou=sm1ou1,
$BASEDN
olcRootDN: ou=sm1ou1,
$BASEDN
...
...
@@ -533,9 +535,9 @@ olcRootPW: $PASSWD
dn: olcDatabase={3}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {3}
$BACKEND
olcDbDirectory:
$SM1_DIR
/sm1ou2
${
nullExclude
}
olcDbDirectory:
$SM1_DIR
/sm1ou2
olcSubordinate: TRUE
olcSuffix: ou=sm1ou2,
$BASEDN
olcRootDN: ou=sm1ou1,
$BASEDN
...
...
@@ -570,9 +572,9 @@ fi
$LDAPADD
-D
cn
=
config
-H
$URI3
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SM2_DIR
/db
${
nullExclude
}
olcDbDirectory:
$SM2_DIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$UPDATEDN
...
...
@@ -588,27 +590,27 @@ olcSpCheckpoint: 1 1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SM2_DIR
/ou2
${
nullExclude
}
olcDbDirectory:
$SM2_DIR
/ou2
olcSubordinate: TRUE
olcSuffix: ou=ou2,
$BASEDN
olcRootDN:
$UPDATEDN
dn: olcDatabase={2}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {2}
$BACKEND
olcDbDirectory:
$SM2_DIR
/sm1ou1
${
nullExclude
}
olcDbDirectory:
$SM2_DIR
/sm1ou1
olcSubordinate: TRUE
olcSuffix: ou=sm1ou1,
$BASEDN
olcRootDN:
$UPDATEDN
dn: olcDatabase={3}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {3}
$BACKEND
olcDbDirectory:
$SM2_DIR
/sm2ou1
${
nullExclude
}
olcDbDirectory:
$SM2_DIR
/sm2ou1
olcSubordinate: TRUE
olcSuffix: ou=sm2ou1,
$BASEDN
olcRootDN: ou=sm2ou1,
$BASEDN
...
...
@@ -616,9 +618,9 @@ olcRootPW: $PASSWD
dn: olcDatabase={4}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {4}
$BACKEND
olcDbDirectory:
$SM2_DIR
/sm2ou2
${
nullExclude
}
olcDbDirectory:
$SM2_DIR
/sm2ou2
olcSubordinate: TRUE
olcSuffix: ou=sm2ou2,
$BASEDN
olcRootDN: ou=sm2ou1,
$BASEDN
...
...
@@ -720,9 +722,9 @@ echo "Adding database config on central search..."
$LDAPADD
-D
cn
=
config
-H
$URI4
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SSC_DIR
/db
${
nullExclude
}
olcDbDirectory:
$SSC_DIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$UPDATEDN
...
...
@@ -738,9 +740,9 @@ echo "Adding database config on site1 search..."
$LDAPADD
-D
cn
=
config
-H
$URI5
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SS1_DIR
/db
${
nullExclude
}
olcDbDirectory:
$SS1_DIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$UPDATEDN
...
...
@@ -756,9 +758,9 @@ echo "Adding database config on site2 search..."
$LDAPADD
-D
cn
=
config
-H
$URI6
-y
$CONFIGPWF
<<
EOF
>>
$TESTOUT
2>&1
dn: olcDatabase={1}
$BACKEND
,cn=config
objectClass: olcDatabaseConfig
objectClass: olc
${
BACKEND
}
Config
${
nullExclude
}
objectClass: olc
${
BACKEND
}
Config
olcDatabase: {1}
$BACKEND
olcDbDirectory:
$SS2_DIR
/db
${
nullExclude
}
olcDbDirectory:
$SS2_DIR
/db
olcSuffix:
$BASEDN
olcRootDN:
$UPDATEDN
...
...
@@ -841,7 +843,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI2
\
-s
base
-b
"ou=ou1,
$BASEDN
"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -860,7 +862,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI3
\
-s
base
-b
"ou=ou1,
$BASEDN
"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -961,7 +963,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI1
\
-s
base
-b
"ou=sm2ou1,
$BASEDN
"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1009,7 +1011,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI1
\
-s
base
-b
"ou=sm1ou1,
$BASEDN
"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1082,7 +1084,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI4
\
-s
base
-b
"
$BASEDN
"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1101,7 +1103,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI5
\
-s
base
-b
"
$BASEDN
"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1120,7 +1122,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI6
\
-s
base
-b
"
$BASEDN
"
\
'(objectClass=*)'
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1506,6 +1508,8 @@ ERRORS=`expr $ERRORS + $CSN_ERRORS`
EOF
test
$BACKEND
=
null
&&
echo
:
>
$TESTDIR
/checkcsn.sh
chmod
+x
$TESTDIR
/checkcsn.sh
...
...
@@ -1540,7 +1544,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI4
\
-s
base
-b
"ou=ou1,
$BASEDN
"
\
"(description=Modify
$MNUM
)"
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1559,7 +1563,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI5
\
-s
base
-b
"ou=ou1,
$BASEDN
"
\
"(description=Modify
$MNUM
)"
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1578,7 +1582,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI6
\
-s
base
-b
"ou=ou1,
$BASEDN
"
\
"(description=Modify
$MNUM
)"
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1621,7 +1625,7 @@ for i in 1 2 3 4 5; do
RESULT
=
`
$LDAPSEARCH
-H
$URI6
\
-s
base
-b
"ou=ou2,
$BASEDN
"
\
"(description=Modify
$MNUM
)"
2>&1 |
awk
'/^dn:/ {print "OK"}'
`
if
test
"x
$RESULT
"
=
"xOK"
;
then
if
test
"x
$RESULT
$nullOK
"
=
"xOK"
;
then
RC
=
0
break
fi
...
...
@@ -1690,7 +1694,7 @@ for i in 1 2 3 4 5; do