为什么我的oracle10g在linux as4上无法开机自动启动

[复制链接]
查看11 | 回复0 | 2006-9-18 10:12:00 | 显示全部楼层 |阅读模式
我按以下方式配置了启动文件:
编辑 /etc/oratab
ora10g:/home/oracle/OraHome_1:Y
做一个启动脚本 /etc/init.d/dbora ,如下所示:
#!/bin/sh
# description: Oracle auto start-stop script.
# chkconfig: - 20 80
#
# 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
# Oracle database in ORA_HOME.
ORA_HOME=/datas/app/oracle/product/10.2.0/db_1
ORA_OWNER=oracle
if [ ! -f $ORA_HOME/bin/dbstart ]
then
echo "Oracle startup: cannot start"
exit
fi
case "$1" in
'start')
# Start the Oracle databases:
# The following command assumes that the oracle login
# will not prompt the user for any values
su - $ORA_OWNER -c $ORA_HOME/bin/dbstart
su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl start"
;;
'stop')
# Stop the Oracle databases:
# The following command assumes that the oracle login
# will not prompt the user for any values
su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl stop"
su - $ORA_OWNER -c $ORA_HOME/bin/dbshut
;;
'restart')
$0 stop
$0 start
;;
esac
赋予执行权限
chmod 750 /etc/init.d/dbora
作成以下链接:
ln -s /etc/init.d/dbora /etc/rc0.d/K10dbora
ln -s /etc/init.d/dbora /etc/rc3.d/S99dbora
执行以下命令:
chkconfig --level 345 dbora on
但是启动服务出错,在服务里面 dbora显示:
evn: /etc/init.d/dbora: No such file or directory.
多谢!!
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行