Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Solaris 2.6 startup/shutdown scripts

Re: Solaris 2.6 startup/shutdown scripts

From: John D Groenveld <groenvel_at_cse.psu.edu>
Date: 14 Apr 1998 16:37:58 -0400
Message-ID: <6h0hf6$3q9$1@tholian.cse.psu.edu>


7.3.x versions of dbstart/dbshut only included support for sqldba which was EOL'd. If you intend to link this to /etc/rc0.d/K00dbora, beware that dbshut does a normal shutdown which will wait for users to disconnect. You might consider changing that to shutdown immediate. John
groenveld_at_acm.org

#!/sbin/sh
# /etc/init.d/dbora to be linked to /etc/rc3.d/S99dbora- JDG 19960623
#
# Set ORA_HOME to be equivalent to the ORACLE_HOME from
# which you wish to execute dbstart and dbshut
# set ORA_OWNER to the user id of the owner of the
# database in ORA_HOME.

ORA_HOME=/home/hostname.1/oracle/product/7.2.3 ORA_OWNER=oracle  

if [ ! -f $ORA_HOME/bin/dbstart -o ! -d $ORA_HOME ] then

        echo "Oracle startup: cannot start" exit
fi
case "$1" in
 'start')

        #Start the oracle database:  

        # cleans up lock files for SQLNet in case of shutdown
        if [ -f /var/tmp/o/* ]; then
                rm -f /var/tmp/o/s*
        fi
        su - $ORA_OWNER -c $ORA_HOME/bin/dbstart
        su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl start"
        ;;
 
 'stop')
        # Stop the Oracle databases:
        su - $ORA_OWNER -c $ORA_HOME/bin/dbshut
        su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl stop"
        ;;

esac Received on Tue Apr 14 1998 - 15:37:58 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US