需求: Need to drop old disks and add new disks to OCR diskgroup online.
Reference 文档 ID 2073993.1 Adding new storage disks and Dropping old storage disks from OCR ,Vote diskgroup
检查:
Three disks in OCR_VOTE diskgroup.
[oragrid@node1 ~]$ ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 4
Total space (kbytes) : 409568
Used space (kbytes) : 1888
Available space (kbytes) : 407680
ID : 1572912627
Device/File Name : +VOTEDISK
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 bypassed due to non-privileged user
NAME PATH FAILGROUP STATE
------------------------------ ---------------------------------------- ------------------------------ --------
VOTEDISK_0005 /dev/oracleasm/disks/ASMLIB2 VOTE3 NORMAL
VOTEDISK_0001 /dev/oracleasm/disks/ASMLIB3 VOTE1 NORMAL
VOTEDISK_0004 /dev/oracleasm/disks/ASMLIB4 VOTE2 NORMAL
[oragrid@node1 ~]$ crsctl query css votedisk
## STATE File Universal Id File Name Disk group
-- ----- ----------------- --------- ---------
1. ONLINE 169d280e18854fddbf3b40916d5f61b2 (/dev/oracleasm/disks/ASMLIB2) [VOTEDISK]
2. ONLINE 81e4cb2409104f59bf8b37f6eddac70a (/dev/oracleasm/disks/ASMLIB3) [VOTEDISK]
3. ONLINE 469e845615d94fcabfb7fe63be8cbc1d (/dev/oracleasm/disks/ASMLIB4) [VOTEDISK]
So adding three more disks , each disk to each failgroup
New disks
/dev/oracleasm/disks/OCRVD_NEW1
/dev/oracleasm/disks/OCRVD_NEW2
/dev/oracleasm/disks/OCRVD_NEW3
Adding new disks
SQL> alter diskgroup VOTEDISK add
failgroup VOTE1 disk '/dev/oracleasm/disks/OCRVD_NEW1'
failgroup VOTE2 disk '/dev/oracleasm/disks/OCRVD_NEW2'
failgroup VOTE3 disk '/dev/oracleasm/disks/OCRVD_NEW3' rebalance power 6;
Diskgroup altered.
check if the rebalance got completed. select * from v$asm_operation;
Checking if the old disks and new disks are visible in v$asm_disk
NAME PATH FAILGROUP STATE
------------------------------ ---------------------------------------- ------------------------------ --------
VOTEDISK_0005 /dev/oracleasm/disks/ASMLIB2 VOTE3 NORMAL
VOTEDISK_0001 /dev/oracleasm/disks/ASMLIB3 VOTE1 NORMAL
VOTEDISK_0003 /dev/oracleasm/disks/OCRVD_NEW3 VOTE3 NORMAL
VOTEDISK_0000 /dev/oracleasm/disks/OCRVD_NEW1 VOTE1 NORMAL
VOTEDISK_0004 /dev/oracleasm/disks/ASMLIB4 VOTE2 NORMAL
VOTEDISK_0002 /dev/oracleasm/disks/OCRVD_NEW2 VOTE2 NORMAL
6 rows selected.
Drop the old disks
alter diskgroup votedisk drop disk VOTEDISK_0001,VOTEDISK_0005,VOTEDISK_0004 rebalance power 6;
check v$asm_operation;
Once the rebalance is done , query the below command in all the nodes to check if the new disks are listing as Voting disks
[oragrid@node1 ~]$ crsctl query css votedisk
## STATE File Universal Id File Name Disk group
-- ----- ----------------- --------- ---------
1. ONLINE ec3ef8924eb64f66bf7201acfa731164 (/dev/oracleasm/disks/OCRVD_NEW1) [VOTEDISK]
2. ONLINE 9ac51729e2f74faabfe6c33207fd9f31 (/dev/oracleasm/disks/OCRVD_NEW2) [VOTEDISK]
3. ONLINE 0da4509b82304f2ebfb68099d72f1dac (/dev/oracleasm/disks/OCRVD_NEW3) [VOTEDISK]