ORACLE RAC重建OCR
OCR 對RAC 來說是非常重要的。 OCR記錄節點成員的配置資訊,如database、ASM、instance、listener、VIP等CRS資源的配置資訊。在日常維護中需要對它進行備份。當然OCR 也會自動備份。 當OCR 出現問題時,有備份的話就使用備份來恢復。 當沒有備份的話就只能重建了。
重建OCR操作如下:
1.停止所有節點的CRS
[root@rac02 bin]# pwd /u01/app/oracle/db_1/bin [root@rac02 bin]# ./crsctl stop crs Stopping resources. This could take several minutes. Successfully stopped CRS resources. Stopping CSSD. Shutting down CSS daemon. Shutdown request successfully issued. [root@rac01 ~]# cd /u01/app/oracle/db_1/bin [root@rac01 bin]# ./crsctl stop crs Stopping CSSD. Shutting down CSS daemon. Shutdown request successfully issued. |
[oracle@rac01 ~]$ echo $CRS_HOME /u01/app/oracle/crs [root@rac01 oracle]# cp -R crs crs.bak [root@rac01 oracle]# ls admin crs crs.bak db_1 oraInventory [root@rac02 oracle]# ls admin crs db_1 oraInventory [root@rac02 oracle]# cp -R crs crs.bak [root@rac02 oracle]# ls admin crs crs.bak db_1 oraInventory |
[root@rac01 install]# pwd /u01/app/oracle/crs/install [root@rac01 install]# ./rootdelete.sh Shutting down Oracle Cluster Ready Services (CRS): Stopping CSSD. Unable to communicate with the CSS daemon. Shutdown has begun. The daemons should exit soon. Checking to see if Oracle CRS stack is down... Oracle CRS stack is not running. Oracle CRS stack is down now. Removing script for Oracle Cluster Ready services Updating ocr file for downgrade Cleaning up SCR settings in '/etc/oracle/scls_scr' [root@rac02 install]# ./rootdelete.sh |
因為我是在rac01節點上執行安裝的,所以也在該節點執行該命令,只需要在該節點執行就可以了。
[root@rac01 install]# pwd
Removing contents from OCR device |
5.檢查CRS程式,如果沒有返回值,繼續下一步
[root@rac01 install]# ps -e | grep -i 'ocs[s]d' 13665 pts/2 00:00:00 ocssd.bin [root@rac01 install]# ps -e | grep -i 'cr[s]d.bin' [root@rac01 install]# ps -e | grep -i 'ev[m]d.bin' |
6.在安裝節點(第4步中的節點)執行
[root@rac01 crs]# pwd
Setting the permissions on OCR backup directory
NO KEYS WERE WRITTEN. Supply -force parameter to override.
/u01/app/oracle/crs
[root@rac01 crs]# ./root.sh
WARNING: directory '/u01/app/oracle' is not owned by root
WARNING: directory '/u01/app' is not owned by root
WARNING: directory '/u01' is not owned by root
Checking to see if Oracle CRS stack is already configured
Setting up NS directories
Oracle Cluster Registry configuration upgraded successfully
WARNING: directory '/u01/app/oracle' is not owned by root
WARNING: directory '/u01/app' is not owned by root
WARNING: directory '/u01' is not owned by root
clscfg: EXISTING configuration version 3 detected.
clscfg: version 3 is 10G Release 2.
Successfully accumulated necessary OCR keys.
Using ports: CSS=49895 CRS=49896 EVMC=49898 and EVMR=49897.
node
node 1: rac01 rac01-priv rac01
node 2: rac02 rac02-priv rac02
clscfg: Arguments check out successfully.
-force is destructive and will destroy any previous cluster
configuration.
Oracle Cluster Registry for cluster has already been initialized
Startup will be queued to init within 30 seconds.
Adding daemons to inittab
Expecting the CRS daemons to be up within 600 seconds.
CSS is active on these nodes.
rac01
CSS is inactive on these nodes.
rac02
Local node checking complete.
Run root.sh on remaining nodes to start CRS daemons.
7.在剩下的節點執行
[root@rac02 ~]# /u01/app/oracle/crs/root.shWARNING: directory '/u01/app/oracle' is not owned by root
Setting the permissions on OCR backup directory
NO KEYS WERE WRITTEN. Supply -force parameter to override.
在 (0) 節點上建立 VIP 應用程式資源.
|
重建結束;
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/29634949/viewspace-1158549/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- oracle重建ocrOracle
- Oracle RAC 遷移替換 OCR 盤Oracle
- Oracle 12c rac ocr和votedisk管理Oracle
- RAC_OCR管理
- Oracle Database 12c RAC損壞ocr和votedisk恢復實驗OracleDatabase
- 重建共享(db或asm)密碼檔案 in Oracle 19c RAC-20220209ASM密碼Oracle
- oracle RACOracle
- oracle重建索引(二)Oracle索引
- oracle重建索引(一)Oracle索引
- oracle重建索引(三)Oracle索引
- oracle DBA 角色重建Oracle
- Oracle RAC Cache Fusion 系列十七:Oracle RAC DRMOracle
- Oracle 11.2 DataGuard RAC To RAC搭建Oracle
- Oracle RAC CacheFusion 系列十五:Oracle RAC CRServer Part TwoOracleServer
- ORACLE RAC clusterwareOracle
- Oracle RAC Cache Fusion系列十八:Oracle RAC Statisticsand Wait EventsOracleAI
- oracle遷移OCR盤Oracle
- Oracle RAC Cache Fusion 系列十四:Oracle RAC CR Server Part OneOracleServer
- Oracle RAC Cache Fusion 系列十:Oracle RAC Enqueues And Lock Part 1OracleENQ
- 【RAC】Oracle RAC如何修改心跳網路Oracle
- oracle rac 增加磁碟Oracle
- Oracle RAC Wait EventsOracleAI
- 【RAC】Oracle rac 如何修改公網及vipOracle
- Oracle RAC Cache Fusion 系列九:Oracle RAC 分散式資源管理(二)Oracle分散式
- Oracle RAC Cache Fusion 系列八:Oracle RAC 分散式資源管理(一)Oracle分散式
- Oracle RAC更新補丁Oracle
- Oracle RAC新增節點Oracle
- 4.2.1.12 規劃 Oracle RACOracle
- Oracle RAC自啟動Oracle
- Oracle:RAC 程式簡介Oracle
- Networker備份oracle racOracle
- Oracle RAC+DG搭建Oracle
- G003-ORACLE-INS-RAC-01 ORACLE 19C RAC Ins ON OEL 7.8Oracle
- 【BUILD_ORACLE】Oracle 19c RAC搭建(六)建立RAC資料庫UIOracle資料庫
- Oracle 11g刪除庫重建Oracle
- 【RAC】Oracle RAC上線測試場景介紹Oracle
- Oracle RAC一鍵部署004(RAC引數校驗)Oracle
- oracle RAC手動配置互信Oracle
- Oracle RAC序列效能測試Oracle