开机启动oracle的脚本

发表于:2007-05-26来源:作者:点击数: 标签:
Filename:/etc/rc2.d/S99dbora817 1.Content: #!/bin/sh ORACLE_HOME=/opt/oracle/product/8.1.7 case in start) su - oracle -c $ORACLE_HOME/bin/dbstart su - oracle -c $ORACLE_HOME/bin/lsnrctl start ;; stop) su - oracle -c $ORACLE_HOME/bin/dbshut
Filename:/etc/rc2.d/S99dbora817


1.Content:

#!/bin/sh
ORACLE_HOME=/opt/oracle/product/8.1.7
case "" in
start)
su - oracle -c "$ORACLE_HOME/bin/dbstart" &
su - oracle -c "$ORACLE_HOME/bin/lsnrctl start" &
;;
stop)
su - oracle -c "$ORACLE_HOME/bin/dbshut" &
esac




2.then, modify the files dbshut and dbstart to fit your system.
2.1. modify the dbshut's "ORATAB=/etc/oratab" to "ORATAB=/var/opt/oracle/oratab"
2.2. modify the dbstart's "ORATAB=/etc/oratab" to "ORATAB=/var/opt/oracle/oratab"
2.3. modify the /var/opt/oracle/oratab to "dbora817:/opt/oracle/product/8.1.7:Y"

原文转自:http://www.ltesting.net