1.Log in as the root user.
2.Edit the oratab file.
# vi /var/opt/oracle/oratab
Code:
db1:/u01/app/oracle/product/10.2.0/dbhome:Y
db2:/u01/app/oracle/product/10.2.0/dbhome:Y
db3:/u01/app/oracle/product/10.2.0/dbhome:Y
Then still root I created a file in /etc/init.d called dbora. Like bellow….
Code:
#! /bin/sh -x
#
# Change the value of ORACLE_HOME to specify the correct Oracle home
# directory for your installation.
ORACLE_HOME=/u01/app/oracle/product/10.2.0/dbhome
#
# Change the value of ORACLE to the login name of the
# oracle owner at your site.
#
ORACLE=oracle
PATH=${PATH}:$ORACLE_HOME/bin
HOST=`hostname`
PLATFORM=`uname`
export ORACLE_HOME PATH
#
if [ ! "$2" = "ORA_DB" ] ; then
if [ "$PLATFORM" = "HP-UX" ] ; then
remsh $HOST -l $ORACLE -n "$0 $1 ORA_DB"
exit
else
rsh $HOST -l $ORACLE $0 $1 ORA_DB
exit
fi
fi
#
case $1 in
'start')
$ORACLE_HOME/bin/dbstart $ORACLE_HOME &
;;
'stop')
$ORACLE_HOME/bin/dbshut $ORACLE_HOME &
;;
*)
echo "usage: $0 {start|stop}"
exit
;;
esac
#
exit
then …
Change the group of the dbora file to the OSDBA group (typically dba), and set the permissions to 750: ( still root )
Code:
# chgrp dba dbora
# chmod 750 dbora
After that, still root..
Code:
# ln -s /etc/init.d/dbora /etc/rc3.d/K01dbora
# ln -s /etc/init.d/dbora /etc/rc3.d/S99dbora
After that reboot the system, but db just don't start at the boot. I can start manually without problems. Now you tell me what and where I did wrong?
Bookmarks