Oracle RAC正常的重啟順序:
Oracle 10g rac:
一般10g RAC (ASM) 開關機順序如下:
1)停止 Oracle RAC 10g 環境
先停止 Oracle 執行個體。當此執行個體(和相關服務)關閉後,關閉 ASM 執行個體。
最後,關閉節點應用程式(虛擬 IP、GSD、TNS 監聽器和 ONS)。
$ export ORACLE_SID=escdb1
$ emctl stop dbconsole
$ srvctl stop instance -d ecsdb -i ecsdb1
$ srvctl stop asm -n ecsrac01
$ srvctl stop nodeapps -n ecsrac01
2)啟動 Oracle RAC 10g 環境
第一步是啟動節點應用程式(虛擬 IP、GSD、TNS 監聽器和 ONS)。當成功啟動節點應用程式後,
啟動 ASM 執行個體。最後,啟動 Oracle 執行個體(相關服務)以及企業管理器資料庫控制台。
$ export ORACLE_SID=ecsdb1
$ srvctl start nodeapps -n ecsrac01
$ srvctl start asm -n ecsrac01
$ srvctl start instance -d ecsdb -i ecsdb1
$ emctl start dbconsole
但是在11G RAC中, 資料庫及執行個體關閉都可以沿用10g的命令進行, 使用 srvctl stop asm -n ecsrac01 關閉
asm的時候,出現問題, 關閉報錯 。
oracle 11g rac:
1 先關閉資料庫:
oracle$ srvctl stop database -d rac (根據自己的情況設定資料庫名)
2 再關閉crs 服務
[root@rac1 ~]# /opt/11202/11.2.0/grid/bin/crsctl stop crs
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'rac1'
CRS-2673: Attempting to stop 'ora.crsd' on 'rac1'
CRS-2790: 正在啟動關閉 'rac1' 上叢集就緒服務管理的資源的操作
CRS-2673: 嘗試停止 'ora.oc4j' (在 'rac1' 上)
CRS-2673: 嘗試停止 'ora.gsd' (在 'rac1' 上)
CRS-2673: 嘗試停止 'ora.DATA1.dg' (在 'rac1' 上)
CRS-2673: 嘗試停止 'ora.DATA2.dg' (在 'rac1' 上)
CRS-2673: 嘗試停止 'ora.LISTENER.lsnr' (在 'rac1' 上)
CRS-2673: 嘗試停止 'ora.YANGQL.lsnr' (在 'rac1' 上)
CRS-2677: 成功停止 'ora.YANGQL.lsnr' (在 'rac1' 上)
CRS-2677: 成功停止 'ora.LISTENER.lsnr' (在 'rac1' 上)
CRS-2673: 嘗試停止 'ora.rac1.vip' (在 'rac1' 上)
CRS-2677: 成功停止 'ora.rac1.vip' (在 'rac1' 上)
CRS-2672: 嘗試啟動 'ora.rac1.vip' (在 'rac2' 上)
CRS-2677: 成功停止 'ora.gsd' (在 'rac1' 上)
CRS-2676: 成功啟動 'ora.rac1.vip' (在 'rac2' 上)
CRS-2677: 成功停止 'ora.DATA2.dg' (在 'rac1' 上)
CRS-2677: 成功停止 'ora.oc4j' (在 'rac1' 上)
CRS-2672: 嘗試啟動 'ora.oc4j' (在 'rac2' 上)
CRS-2677: 成功停止 'ora.DATA1.dg' (在 'rac1' 上)
CRS-2673: 嘗試停止 'ora.asm' (在 'rac1' 上)
CRS-2677: 成功停止 'ora.asm' (在 'rac1' 上)
CRS-2676: 成功啟動 'ora.oc4j' (在 'rac2' 上)
CRS-2673: 嘗試停止 'ora.ons' (在 'rac1' 上)
CRS-2677: 成功停止 'ora.ons' (在 'rac1' 上)
CRS-2673: 嘗試停止 'ora.net1.network' (在 'rac1' 上)
CRS-2677: 成功停止 'ora.net1.network' (在 'rac1' 上)
CRS-2792: 關閉 'rac1' 上叢集就緒服務管理的資源的操作已完成
CRS-2677: Stop of 'ora.crsd' on 'rac1' succeeded
CRS-2673: Attempting to stop 'ora.crf' on 'rac1'
CRS-2673: Attempting to stop 'ora.ctssd' on 'rac1'
CRS-2673: Attempting to stop 'ora.evmd' on 'rac1'
CRS-2673: Attempting to stop 'ora.asm' on 'rac1'
CRS-2673: Attempting to stop 'ora.mdnsd' on 'rac1'
CRS-2677: Stop of 'ora.evmd' on 'rac1' succeeded
CRS-2677: Stop of 'ora.asm' on 'rac1' succeeded
CRS-2673: Attempting to stop 'ora.cluster_interconnect.haip' on 'rac1'
CRS-2677: Stop of 'ora.crf' on 'rac1' succeeded
CRS-2677: Stop of 'ora.mdnsd' on 'rac1' succeeded
CRS-2677: Stop of 'ora.cluster_interconnect.haip' on 'rac1' succeeded
CRS-2677: Stop of 'ora.ctssd' on 'rac1' succeeded
CRS-2673: Attempting to stop 'ora.cssd' on 'rac1'
CRS-2677: Stop of 'ora.cssd' on 'rac1' succeeded
CRS-2673: Attempting to stop 'ora.gipcd' on 'rac1'
CRS-2673: Attempting to stop 'ora.diskmon' on 'rac1'
CRS-2677: Stop of 'ora.diskmon' on 'rac1' succeeded
CRS-2677: Stop of 'ora.gipcd' on 'rac1' succeeded
CRS-2673: Attempting to stop 'ora.gpnpd' on 'rac1'
CRS-2677: Stop of 'ora.gpnpd' on 'rac1' succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'rac1' has completed
CRS-4133: Oracle High Availability Services has been stopped.
在11g中 11.2.0.2 中 ocr 服務的資訊存放在asm 磁碟上,是依賴於asm的 ,所以要關閉crs 而不是直接關閉asm執行個體