安装CRS过程中,第二节点执行VIPCA时候出现下面报错,晕了半天,终于找到问题根源并解决:
CRS-0215:Could not start resource 'ora.rac2.ons'.请查看日志文件“/u01/app/oracle/product/10.2.0/crs/log/rac2/racg/ora.rac2.ons.log”
检查ora.rac2.ons.log文件内容如下:
Oracle Database 10g CRS Release 10.2.0.1.0 Production Copyright 1996, 2005 Oracle.All rights reserved.
2007-06-06 16:24:44.791: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: Number of onsconfiguration retrieved, numcfg = 0
Failed to get IP for localhost (4)
Failed to get IP for localhost (4)
onsctl: ons failed to start
2007-06-06 16:24:44.792: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: clsrcexecut: env ORACLE_CONFIG_HOME=/u01/app/oracle/product/10.2.0/crs
2007-06-06 16:24:44.792: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: clsrcexecut: cmd = /u01/app/oracle/product/10.2.0/crs/bin/racgeut -e _USR_ORA_DEBUG=0 540 /u01/app/oracle/product/10.2.0/crs/bin/onsctl start
2007-06-06 16:24:44.792: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: clsrcexecut: rc = 1, time = 197.460s
2007-06-06 16:27:59.296: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: Number of onsconfiguration retrieved, numcfg = 0
ons is not running ...
2007-06-06 16:28:00.300: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: clsrcexecut: env ORACLE_CONFIG_HOME=/u01/app/oracle/product/10.2.0/crs
2007-06-06 16:28:00.300: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: clsrcexecut: cmd = /u01/app/oracle/product/10.2.0/crs/bin/racgeut -e _USR_ORA_DEBUG=0 540 /u01/app/oracle/product/10.2.0/crs/bin/onsctl ping
2007-06-06 16:28:00.300: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: clsrcexecut: rc = 1, time = 195.500s
2007-06-06 16:28:00.301: [ RACG][3086912256] [24496][3086912256][ora.rac2.ons]: end for resource = ora.rac2.ons, action = start, status = 1, time = 393.160s
2007-06-06 16:37:00.999: [ RACG][3086912256] [592][3086912256][ora.rac2.ons]: onsctl: shutting down ons daemon ...
timeout: killed the spawned process
2007-06-06 16:37:01.000: [ RACG][3086912256] [592][3086912256][ora.rac2.ons]: clsrcexecut: env ORACLE_CONFIG_HOME=/u01/app/oracle/product/10.2.0/crs
2007-06-06 16:37:01.000: [ RACG][3086912256] [592][3086912256][ora.rac2.ons]: clsrcexecut: cmd = /u01/app/oracle/product/10.2.0/crs/bin/racgeut -e _USR_ORA_DEBUG=0 540 /u01/app/oracle/product/10.2.0/crs/bin/onsctl stop
2007-06-06 16:37:01.000: [ RACG][3086912256] [592][3086912256][ora.rac2.ons]: clsrcexecut: rc = 99, time = 540.290s
感觉是hosts文件内容有错,赶紧检查第二个节点hosts文件:
# Do not remove the following line, or various programs
# that require network functionality will fail.
192.168.0.217 rac1
192.168.0.219 rac2
10.10.10.217 rac1-priv
10.10.10.219 rac2-priv
192.168.0.117 rac1-vip
192.168.0.119 rac2-vip
诡异,怎么127.0.0.1这个ip没有了,从RAC1虚拟机复制过来的,怎么少掉了一个127.0.0.1的IP??
添加进去之后重新手动启动'ora.rac2.ons'
$crs_start -f 'ora.rac2.ons'
执行成功!
Retry上面的CRS安装,OK,这次没问题了!
很怪的问题,不过总算解决了。