重启linux系统后
首先检查 :
#su - oracle
$ cd /u01/app/oracle/product/11.2.0/grid/bin
$ ./crsctl chech has
如果显示ohasd是not online,则是没有启动
$./crs_stat -t
如果显示没有crs资源,则是资源没有启动
其次处理:
$ sh -x /u01/app/oracle/product/11.2.0/grid/bin/crsctl check has
$ cd /u01/app/oracle/product/11.2.0/grid/crs/install
$ su
$ oracle
# ./roothas.pl -deconfig -force -verbose
# cd /u01/app/oracle/product/11.2.0/grid
# ./root.sh
(如果有用到的语句dd if=/var/tmp/.oracle/npohasd of=/dev/null bs=1024 count=1)
再切换到oracle用户下
$ cd /u01/app/oracle/product/11.2.0/grid/bin
$ ./crsctl stat res -t //查询资源状态
$ ./crsctl start res -all //启动所有资源
Name
------------------------------------------------------------
ora.cssd
ora.diskmon
$ srvctl add asm
$ ./crsctl start res ora.asm
$ ./crs_stat -t
Name
------------------------------------------------------------
ora.asm
ora.cssd
ora.diskmon
再添加ora.DATA.dg
$ ./crs_stat -t
之后登录sqlplus,startup等待mount上,就可以了,如果不行尝试以下步骤。
[oracle@localhost test]$ srvctl start database -d orcl
ORACLE_SID = [+ASM] ? +ASM
The Oracle base for ORACLE_HOME=/u01/app/oracle/product/11.2.0/grid is /u01/app/oracle
--------------------------------------------------------------------------------
NAME
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA.dg
ora.DATA1.dg
ora.asm
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.cssd
ora.diskmon
ora.orcl.db