summaryrefslogtreecommitdiffstats
path: root/ldap/cm
diff options
context:
space:
mode:
authorNoriko Hosoi <nhosoi@redhat.com>2005-09-02 23:33:48 +0000
committerNoriko Hosoi <nhosoi@redhat.com>2005-09-02 23:33:48 +0000
commit85ac7b3aa108cf0049cf83e2838e2b6c6f5491a6 (patch)
treee6557b64a16730520d678e0d776718ef87489000 /ldap/cm
parent516db9420c77cb4dd9cd00ad93cabeb14b3d4041 (diff)
downloadds-85ac7b3aa108cf0049cf83e2838e2b6c6f5491a6.tar.gz
ds-85ac7b3aa108cf0049cf83e2838e2b6c6f5491a6.tar.xz
ds-85ac7b3aa108cf0049cf83e2838e2b6c6f5491a6.zip
[167478] setup script needs to check the DS instance
if the instance dir exists, run ns-config with "-r".
Diffstat (limited to 'ldap/cm')
-rwxr-xr-xldap/cm/newinst/setup13
1 files changed, 12 insertions, 1 deletions
diff --git a/ldap/cm/newinst/setup b/ldap/cm/newinst/setup
index 45bc474c..3d7819ed 100755
--- a/ldap/cm/newinst/setup
+++ b/ldap/cm/newinst/setup
@@ -248,9 +248,20 @@ if ! [ $silent ]; then
echo "SuiteSpotGroup = $group" >> $inffile
echo ServerRoot = `pwd` >> $inffile
+ # check if ds instance directory exists or not
+ # if it does, run ns-config with the reconfigure option
+ doreconfig=""
+ for x in `ls -d slapd-*`
+ do
+ if [ -d $x ]; then
+ doreconfig="-r"
+ break
+ fi
+ done
+
# first, run ds
cd bin/slapd/admin/bin
- ./ns-config -f $inffile -l $logfile -m $installmode || doExit
+ ./ns-config -f $inffile -l $logfile -m $installmode $doreconfig || doExit
cd ../../../..
# next, run admin