Hi list,

A colleague asked me to append this Oracle init script - perhaps it will
help:

#!/bin/sh
#
# Run-level startup script for Oracle and Listener startup and shutdown
#
#Description: Run dbstart on boot and dbshut on shutdown of Linux

ORA_HOME="/oradbf/O10g"
ORA_OWNER="oracle"

# check to see of executable is there

if [ ! -f $ORA_HOME/bin/dbstart -o ! -d $ORA_HOME ]
then
      echo "Oracle startup: cannot start"
      exit 1
fi

#case on startup or shutdown
case "$1" in
      start)
          echo -n "Starting Oracle: "
          su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl start"
          su - $ORA_OWNER -c $ORA_HOME/bin/dbstart
          su - $ORA_OWNER -c $ORA_HOME/bin/dbstart
          echo "OK"
          ;;
      stop)
          echo -n "Shutdown Oracle: "
          su - $ORACLE_OWNER -c "$ORACLE_HOME/bin/lsnrctl stop"
          su - $ORA_OWNER -c $ORA_HOME/bin/dbshut
          echo "OK"
          ;;
      reload|restart)
         $0 stop
         $0 start
         ;;
     *)
        echo "USAGE: $0 start|stop|restart|reload"
esac
exit 0

"Mike MacIsaac" <[EMAIL PROTECTED]>   (845) 433-7061

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390

Reply via email to