安装11.2.0.3 RAC Grid 执行Root.sh报错
文章来自:
安装11.2.0.3 RAC grid 执行root.sh报错
1 root wallet 2 root wallet cert 3 root cert export 4 peer wallet 5 profile reader wallet 6 pa wallet 7 peer wallet keys 8 pa wallet keys 9 peer cert request 10 pa cert request 11 peer cert 12 pa cert 13 peer root cert TP 14 profile reader root cert TP 15 pa root cert TP 16 peer pa cert TP 17 pa peer cert TP 18 profile reader pa cert TP 19 profile reader peer cert TP 20 peer user cert 21 pa user cert 22 Adding Clusterware entries to inittab 23 CRS-2672: Attempting to start 'ora.mdnsd' on 'tip01' 24 CRS-2676: Start of 'ora.mdnsd' on 'tip01' succeeded 25 CRS-2672: Attempting to start 'ora.gpnpd' on 'tip01' 26 CRS-2676: Start of 'ora.gpnpd' on 'tip01' succeeded 27 CRS-2672: Attempting to start 'ora.cssdmonitor' on 'tip01' 28 CRS-2672: Attempting to start 'ora.gipcd' on 'tip01' 29 CRS-2676: Start of 'ora.cssdmonitor' on 'tip01' succeeded 30 CRS-2676: Start of 'ora.gipcd' on 'tip01' succeeded 31 CRS-2672: Attempting to start 'ora.cssd' on 'tip01' 32 CRS-2672: Attempting to start 'ora.diskmon' on 'tip01' 33 CRS-2676: Start of 'ora.diskmon' on 'tip01' succeeded 34 CRS-2676: Start of 'ora.cssd' on 'tip01' succeeded 35 36 已成功创建并启动 ASM。 37 38 已成功创建磁盘组OCR。 39 40 clscfg: -install mode specified 41 Successfully accumulated necessary OCR keys. 42 Creating OCR keys for user 'root', privgrp 'root'.. 43 Operation successful. 44 CRS-4256: Updating the profile 45 Successful addition of voting disk 86e6db2173634f7abf99a8771f48cfd7. 46 Successful addition of voting disk a4974d910f144f4abf5907f693751710. 47 Successful addition of voting disk 048a68d2af584f8cbfae02d943e11d67. 48 Successfully replaced voting disk group with +OCR. 49 CRS-4256: Updating the profile 50 CRS-4266: Voting file(s) successfully replaced 51 ## STATE File Universal Id File Name Disk group 52 -- ----- ----------------- --------- --------- 53 1. ONLINE 86e6db2173634f7abf99a8771f48cfd7 (ORCL:OCR_VOL1) [OCR] 54 2. ONLINE a4974d910f144f4abf5907f693751710 (ORCL:OCR_VOL2) [OCR] 55 3. ONLINE 048a68d2af584f8cbfae02d943e11d67 (ORCL:OCR_VOL3) [OCR] 56 Located 3 voting disk(s). 57 CRS-2672: Attempting to start 'ora.asm' on 'tip01' 58 CRS-2676: Start of 'ora.asm' on 'tip01' succeeded 59 CRS-2672: Attempting to start 'ora.OCR.dg' on 'tip01' 60 CRS-2676: Start of 'ora.OCR.dg' on 'tip01' succeeded 61 /u01/app/11.2.0/grid/product/db_1/bin/srvctl start nodeapps -n tip01 ... failed 62 FirstNode configuration failed at /u01/app/11.2.0/grid/product/db_1/crs/install/crsconfig_lib.pm line 9196. 63 /u01/app/11.2.0/grid/product/db_1/perl/bin/perl 64 -I/u01/app/11.2.0/grid/product/db_1/perl/lib -I/u01/app/11.2.0/grid/product/db_1/crs/install 65 /u01/app/11.2.0/grid/product/db_1/crs/install/rootcrs.pl execution failed 66 67 68 第一节点执行root.sh最后报错 69 70 检查下oraagent_grid.log发现以下错误 71 无法解析 (:CLSN00010:)无法解析 localhost (为接口 any) 都是这种报错 72 73 [root@tip01 oraagent_grid]# more oraagent_grid.log 74 75 2012-05-23 19:36:40.711: [ AGFW][1394043200] {1:31151:202} Agent sending reply for: RESOURCE_START[ora.ons tip01 1] ID 409 76 8:562 77 2012-05-23 19:36:40.711: [ora.ons][1360484672] {1:31151:202} [start] execCmd ret = 2 78 2012-05-23 19:36:40.712: [ora.ons][1360484672] {1:31151:202} [start] (:CLSN00010:)getaddrinfo(localhost, 6100, 1) 失败 (Tempo 79 rary failure in name resolution): Connection refused 80 2012-05-23 19:36:40.712: [ora.ons][1360484672] {1:31151:202} [start] (:CLSN00010:)无法解析 localhost (为接口 any) 81 2012-05-23 19:36:40.712: [ora.ons][1360484672] {1:31151:202} [start] (:CLSN00010:)getaddrinfo(localhost, 6100, 1) 失败 (Tempo 82 rary failure in name resolution): Connection refused 83 2012-05-23 19:36:40.712: [ora.ons][1360484672] {1:31151:202} [start] (:CLSN00010:)无法解析 localhost (为接口 any) 84 2012-05-23 19:36:40.712: [ora.ons][1360484672] {1:31151:202} [start] (:CLSN00010:)onsctl start: ons failed to start 85 2012-05-23 19:36:40.712: [ora.ons][1360484672] {1:31151:202} [start] (:CLSN00010:) 86 2012-05-23 19:36:40.712: [ora.ons][1360484672] {1:31151:202} [start] OnsAgent::start } 87 2012-05-23 19:36:40.712: [ora.ons][1360484672] {1:31151:202} [start] (:CLSN00107:) clsn_agent::start } 88 2012-05-23 19:36:40.712: [ AGFW][1360484672] {1:31151:202} Command: start for resource: ora.ons tip01 1 completed with sta 89 tus: SUCCESS 90 2012-05-23 19:36:40.714: [ora.ons][1360484672] {1:31151:202} [check] OnsAgent::check { 91 2012-05-23 19:36:40.714: [ora.ons][1360484672] {1:31151:202} [check] getOracleHomeAttrib: oracle_home = /u01/app/11.2.0/grid/ 92 product/db_1 93 2012-05-23 19:36:40.714: [ AGFW][1394043200] {1:31151:202} Agent sending reply for: RESOURCE_START[ora.ons tip01 1] ID 409 94 8:562 95 2012-05-23 19:36:40.715: [ora.ons][1360484672] {1:31151:202} [check] Utils:execCmd action = 3 flags = 6 ohome = /u01/app/11.2 96 .0/grid/product/db_1/opmn/ cmdname = onsctli. 97 2012-05-23 19:36:40.820: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:)getaddrinfo(localhost, 6100, 1) 失败 (Tempo 98 rary failure in name resolution): Connection refused 99 2012-05-23 19:36:40.820: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:)无法解析 localhost (为接口 any) 100 2012-05-23 19:36:40.820: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:)ons is not running ... 101 2012-05-23 19:36:40.820: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:) 102 2012-05-23 19:36:40.821: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:)Utils:execCmd scls_process_join() uret 2 103 104 2012-05-23 19:36:40.821: [ora.ons][1360484672] {1:31151:202} [check] execCmd ret = 2 105 2012-05-23 19:36:40.821: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:)getaddrinfo(localhost, 6100, 1) 失败 (Tempo 106 rary failure in name resolution): Connection refused 107 2012-05-23 19:36:40.821: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:)无法解析 localhost (为接口 any) 108 2012-05-23 19:36:40.821: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:)ons is not running ... 109 2012-05-23 19:36:40.821: [ora.ons][1360484672] {1:31151:202} [check] (:CLSN00010:) 110 2012-05-23 19:36:40.824: [ USRTHRD][1360484672] {1:31151:202} Ocr Context init default level -1408463520 111 112 113 怀疑是hosts问题 114 115 [root@tip01 ~]# more /etc/hosts 116 117 #eth0-Public IP 118 162.20.1.228 tip01 119 162.20.1.229 tip02 120 121 #eth1 鈥PRIVATE IP 122 192.168.99.228 tip01-priv 123 192.168.99.229 tip02-priv 124 125 #VIP 126 162.20.1.230 tip01-vip 127 162.20.1.231 tip02-vip 128 129 #SCAN 130 162.20.1.232 rac-scan 131 132 原hosts文件缺少127.0.0.1 localhost 133 于是尝试在两个节点添加localhost 134 135 [root@tip01 ~]# more /etc/hosts 136 127.0.0.1 localhost 137 ::1 localhost6.localdomain6 localhost6 138 139 #eth0-Public IP 140 162.20.1.228 tip01 141 162.20.1.229 tip02 142 143 #eth1 鈥PRIVATE IP 144 192.168.99.228 tip01-priv 145 192.168.99.229 tip02-priv 146 147 #VIP 148 162.20.1.230 tip01-vip 149 162.20.1.231 tip02-vip 150 151 #SCAN 152 162.20.1.232 rac-scan 153 154 155 重新执行root.sh 156 157 [root@tip01 db_1]# ./root.sh 158 Performing root user operation for Oracle 11g 159 160 The following environment variables are set as: 161 ORACLE_OWNER= grid 162 ORACLE_HOME= /u01/app/11.2.0/grid/product/db_1 163 164 Enter the full pathname of the local bin directory: [/usr/local/bin]: 165 The contents of "dbhome" have not changed. No need to overwrite. 166 The contents of "oraenv" have not changed. No need to overwrite. 167 The contents of "coraenv" have not changed. No need to overwrite. 168 169 170 Creating /etc/oratab file... 171 Entries will be added to the /etc/oratab file as needed by 172 Database Configuration Assistant when a database is created 173 Finished running generic part of root script. 174 Now product-specific root actions will be performed. 175 176 Using configuration parameter file: /u01/app/11.2.0/grid/product/db_1/crs/install/crsconfig_params 177 Creating trace directory 178 User ignored Prerequisites during installation 179 180 OLR initialization - successful 181 root wallet 182 root wallet cert 183 root cert export 184 peer wallet 185 profile reader wallet 186 pa wallet 187 peer wallet keys 188 pa wallet keys 189 peer cert request 190 pa cert request 191 peer cert 192 pa cert 193 peer root cert TP 194 profile reader root cert TP 195 pa root cert TP 196 peer pa cert TP 197 pa peer cert TP 198 profile reader pa cert TP 199 profile reader peer cert TP 200 peer user cert 201 pa user cert 202 Adding Clusterware entries to inittab 203 CRS-2672: Attempting to start 'ora.mdnsd' on 'tip01' 204 CRS-2676: Start of 'ora.mdnsd' on 'tip01' succeeded 205 CRS-2672: Attempting to start 'ora.gpnpd' on 'tip01' 206 CRS-2676: Start of 'ora.gpnpd' on 'tip01' succeeded 207 CRS-2672: Attempting to start 'ora.cssdmonitor' on 'tip01' 208 CRS-2672: Attempting to start 'ora.gipcd' on 'tip01' 209 CRS-2676: Start of 'ora.cssdmonitor' on 'tip01' succeeded 210 CRS-2676: Start of 'ora.gipcd' on 'tip01' succeeded 211 CRS-2672: Attempting to start 'ora.cssd' on 'tip01' 212 CRS-2672: Attempting to start 'ora.diskmon' on 'tip01' 213 CRS-2676: Start of 'ora.diskmon' on 'tip01' succeeded 214 CRS-2676: Start of 'ora.cssd' on 'tip01' succeeded 215 216 已成功创建并启动 ASM。 217 218 已成功创建磁盘组OCR。 219 220 clscfg: -install mode specified 221 Successfully accumulated necessary OCR keys. 222 Creating OCR keys for user 'root', privgrp 'root'.. 223 Operation successful. 224 CRS-4256: Updating the profile 225 Successful addition of voting disk 232a38e7c66c4fc4bf5a66145114ea3d. 226 Successful addition of voting disk 7bee34f239d74f92bf4cbb5773000b81. 227 Successful addition of voting disk 0329e1ba14914fd1bf7bd7bc86aac045. 228 Successfully replaced voting disk group with +OCR. 229 CRS-4256: Updating the profile 230 CRS-4266: Voting file(s) successfully replaced 231 ## STATE File Universal Id File Name Disk group 232 -- ----- ----------------- --------- --------- 233 1. ONLINE 232a38e7c66c4fc4bf5a66145114ea3d (ORCL:OCR_VOL1) [OCR] 234 2. ONLINE 7bee34f239d74f92bf4cbb5773000b81 (ORCL:OCR_VOL2) [OCR] 235 3. ONLINE 0329e1ba14914fd1bf7bd7bc86aac045 (ORCL:OCR_VOL3) [OCR] 236 Located 3 voting disk(s). 237 CRS-2672: Attempting to start 'ora.asm' on 'tip01' 238 CRS-2676: Start of 'ora.asm' on 'tip01' succeeded 239 CRS-2672: Attempting to start 'ora.OCR.dg' on 'tip01' 240 CRS-2676: Start of 'ora.OCR.dg' on 'tip01' succeeded 241 CRS-2672: Attempting to start 'ora.registry.acfs' on 'tip01' 242 CRS-2676: Start of 'ora.registry.acfs' on 'tip01' succeeded 243 Configure Oracle Grid Infrastructure for a Cluster ... succeeded
安装GRID时,在执行root.sh报错时,首先检查下两个节点的hosts文件IP与主机对应关系是否正确完整,本例就是因为hosts文件不完整导致root.sh执行失败