11gR2 OCR&VOTEDISK 從ASM向裸裝置遷移(EXPIMP方式)

westzq1984發表於2012-09-18
ASM上的OCR是200多M的,而客戶劃的OCR是128M,直接replace會報告裝置太小,於是只好測試下最後一種辦法,EXP/IMP。發現完全可以,步驟如下

[root@database1 ~]# ocrconfig -export /tmp/ocr.dmp
[root@database1 ~]# crsctl stop crs -f
[root@database2 ~]# crsctl stop crs -f
[root@database1 ~]# crsctl start crs -excl -nocrs
[root@database1 ~]# ocrconfig -repair -replace +CRSDG -replacement /dev/raw/raw1
[root@database1 ~]# ocrconfig -import /tmp/ocr.dmp
[root@database1 ~]# ocrcheck
[root@database1 ~]# crsctl stat res -t -init
[root@database1 ~]# crsctl stop crs -f
[root@database1 ~]# crsctl start crs
[root@database1 ~]# ocrconfig -add /dev/raw/raw2
[root@database1 ~]# ocrconfig -add /dev/raw/raw3
[root@database1 ~]# ocrcheck
[root@database1 ~]# crsctl replace votedisk /dev/raw/raw4
[root@database1 ~]# crsctl add css votedisk /dev/raw/raw5 /dev/raw/raw6
[root@database2 ~]# vi /etc/oracle/ocr.loc
ocrconfig_loc=/dev/raw/raw1
ocrmirrorconfig_loc=/dev/raw/raw2
ocrconfig_loc3=/dev/raw/raw3
[root@database2 ~]# crsctl start crs


記錄下遇到的問題

1:Storage too small
root@abmdb01#[/]/oracle/app/11.2/grid/bin/ocrconfig -add /dev/vx/rdsk/ocrvote/lv_ocr_128m_02
PROT-22: Storage too small
PROC-31: Storage device for the cluster registry is too small Operating System error [No such device or address] [6]

新增的裝置檔案比原檔案小,一般建議OCR,VOTEDISK都不要小於280M可用空間
解決辦法用使用EXP/IMP遷移。ADD/DELETE/REPLACE均不行

2.PROT-36
root@abmdb01#[/]/oracle/app/11.2/grid/bin/ocrconfig -add  /test/ocr2
PROT-36: Duplicate or previously used Oracle Cluster Registry location /test/ocr2 cannot be added

檔案系統上,不允許OCR的副本在同一個目錄
新建一個目錄放就OK


3.CRS-4602 & Failure 27
替換OCR前,替換VOTEDISK報該錯誤
[root@database1 ~]# crsctl replace votedisk /dev/raw/raw1 /dev/raw/raw2 /dev/raw/raw3 /dev/raw/raw4 /dev/raw/raw5
Now formatting voting disk: /dev/raw/raw1.
Now formatting voting disk: /dev/raw/raw2.
Now formatting voting disk: /dev/raw/raw3.
Now formatting voting disk: /dev/raw/raw4.
Now formatting voting disk: /dev/raw/raw5.
CRS-4256: Updating the profile
CRS-4602: Failed 27 to add voting file 35b0f54884a04fa9bfeb947155332be8.
CRS-4602: Failed 27 to add voting file 93528e9a62494f35bf0988963c2dc9fa.
CRS-4602: Failed 27 to add voting file 0f549b6e79fc4f77bf958497084871a0.
CRS-4602: Failed 27 to add voting file 72914438e0e84f71bf09ccae80ac2ec8.
CRS-4602: Failed 27 to add voting file 6e4188ecade84f93bf62213af80adebb.
Failure 27 with Cluster Synchronization Services while deleting voting disk.
Failure 27 with Cluster Synchronization Services while deleting voting disk.
Failure 27 with Cluster Synchronization Services while deleting voting disk.
Failure 27 with Cluster Synchronization Services while deleting voting disk.
Failure 27 with Cluster Synchronization Services while deleting voting disk.
CRS-4000: Command Replace failed, or completed with errors.

遷移完OCR後,在遷移VOTEDISK就沒有該問題

4.repair
OCR的位置在/etc/oracle/ocr.loc中指定
repair的作用是強制修改該配置檔案。該命令需要在-excl -nocrs的環境中使用
修改後可以在考慮restore/imp等動作

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/8242091/viewspace-743849/,如需轉載,請註明出處,否則將追究法律責任。

相關文章