#
#
# IDENTIFICATION
-# $Header: /cvsroot/pgsql/src/bin/pg_ctl/Attic/pg_ctl.sh,v 1.1 1999/12/06 07:23:41 ishii Exp $
+# $Header: /cvsroot/pgsql/src/bin/pg_ctl/Attic/pg_ctl.sh,v 1.2 1999/12/06 08:35:34 ishii Exp $
#
#-------------------------------------------------------------------------
CMDNAME=`basename $0`
echo "done."
fi
+ echo "postmaster successfully shut down."
+
else
echo "$CMDNAME: Can't find $PIDFILE."
echo "Is postmaster running?"
pid=`cat $PIDFILE`
fi
+ # no -o given
if [ -z "$POSTOPTS" ];then
- if [ -f $DEFPOSTOPTS ];then
- eval `cat $DEFPOSTOPTS` &
+ if [ $op = "start" ];then
+ # if we are in start mode, then look postmaster.opts.default
+ if [ -f $DEFPOSTOPTS ];then
+ eval `cat $DEFPOSTOPTS` &
+ else
+ echo "$CMDNAME: Can't find $DEFPOSTOPTS"
+ exit 1
+ fi
else
- echo "$CMDNAME: Can't find $DEFPOSTOPTS"
- exit 1
+ # if we are in restart mode, then look postmaster.opts
+ eval `cat $POSTOPTSFILE` &
fi
else
$po_path $POSTOPTS &
done
echo "done."
fi
+
+ echo "postmaster successfully started up."
fi
exit 0