您好,登錄后才能下訂單哦!
1、新建一個磁盤組+NEW
Create diskgroup CRS NORMAL REDUNDANCY
FAILGROUP CRS_0000 disk '/dev/asm-orctest1'
FAILGROUP CRS_0001 disk '/dev/asm-orctest2'
FAILGROUP CRS_0002 disk '/dev/asm-orctest3'
ATTRIBUTE 'compatible.asm' = '11.2';
2、查看ocr備份
[root@rac02 bin]# ./ocrconfig -manualbackup
ocrconfig -showbackup
[root@rac02 bin]# ./ocrconfig -showbackup manual
rac01 2017/08/03 06:47:10 /u01/11.2.0/grid/cdata/rac-cluster/backup_20170803_064710.ocr
rac02 2017/08/01 02:32:01 /u01/11.2.0/grid/cdata/rac-cluster/backup_20170801_023201.ocr
2、2個節點停止集群并修改配置文件(更改里面的磁盤組名字為新建的磁盤組)
./crsctl stop crs
vi /etc/oracle/ocr.loc
3、啟動一個節點到獨占模式并確認磁盤組+NEW是否mount,如沒有,手動mount。
crsctl start crs -excl -nocrs
SQL> select GROUP_NUMBER, NAME,STATE from v$asm_diskgroup;
GROUP_NUMBER NAME STATE
------------ ------------------------------ -----------
1 ASM_DATA1 MOUNTED
2 ASM_FL MOUNTED
3 CRS MOUNTED
4 DATA MOUNTED
4、使用OCR備份恢復OCR到新的磁盤組(注意提前更改ocr.loc)
#./ocrconfig -restore /u01/11.2.0/grid/cdata/rac-cluster/backup_20170801_023201.ocr
[root@rac02 bin]# ./ocrconfig -manualbackup
rac01 2017/08/03 06:47:10 /u01/11.2.0/grid/cdata/rac-cluster/backup_20170803_064710.ocr
rac02 2017/08/01 02:32:01 /u01/11.2.0/grid/cdata/rac-cluster/backup_20170801_023201.ocr
5、恢復votedisk
[root@rac02 bin]# ./crsctl replace votedisk +CRS
[root@rac02 bin]# ./ocrconfig -restore /u01/11.2.0/grid/cdata/rac-cluster/backup_20170801_023201.ocr
[root@rac02 bin]# ./crsctl replace votedisk +CRS
Successful addition of voting disk 99fc4fb627ab4ffabfa4819288ef362d.
Successful addition of voting disk 69c39aef708f4f0abf39c97b4c55dcea.
Successful addition of voting disk 6bef23769bae4f5fbfb594f99707b160.
Successful deletion of voting disk 264b8b526ac54fe9bf80c5eee1350526.
Successfully replaced voting disk group with +CRS.
CRS-4266: Voting file(s) successfully replaced
檢查
ocrcheck---------------------------------------------檢查結果未變化
crsctl query css votedisk
[root@rac02 bin]# ./ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 3
Total space (kbytes) : 262120
Used space (kbytes) : 3480
Available space (kbytes) : 258640
ID : 1128199232
Device/File Name : +DATA
Device/File integrity check succeeded
Device/File not configured
Device/File not configured
Device/File not configured
Device/File not configured
Cluster registry integrity check succeeded
Logical corruption check succeeded
[root@rac02 bin]# ./crsctl query css votedisk
## STATE File Universal Id File Name Disk group
-- ----- ----------------- --------- ---------
1. ONLINE 99fc4fb627ab4ffabfa4819288ef362d (/dev/asm-orctest1) [CRS]
2. ONLINE 69c39aef708f4f0abf39c97b4c55dcea (/dev/asm-orctest2) [CRS]
3. ONLINE 6bef23769bae4f5fbfb594f99707b160 (/dev/asm-orctest3) [CRS]
Located 3 voting disk(s).
6、刪除掉原來
./ocrconfig -delete +DATA
然后重啟集群
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。