更改磁盘组属性
alter diskgroup LH_TEST replace disk LH_TEST_0001 with '/dev/oracleasm/disks/TEST5';
select * from v$asm_attribute where NAME like '%compa%';
alter diskgroup LH_TEST set attribute 'compatible.asm'='12.2.0.0';
调整磁盘组中的磁盘大小
select name, total_mb, free_mb, total_mb - free_mb used_mb, round(100*free_mb/total_mb,2) pct_free from v$asm_diskgroup order by 1;
select NAME,TOTAL_MB/(1024) TOTAL_GB,FREE_MB/1024 FREE_GB,(TOTAL_MB-FREE_MB)/1024 USED_GB,(FREE_MB/TOTAL_MB)*100 FREE_PER from v$asm_diskgroup;
select name,label,path,total_mb,os_mb from v$asm_disk
alter diskgroup DATA resize all size 30G;
重命名磁盘组中的磁盘
select name,label,path,total_mb,os_mb from v$asm_disk
alter diskgroup LH_TEST rename disk 'LH_TEST_0001' to 'LH_TEST_01';
alter diskgroup LH_TEST dismount;
select a.instance_name,a.db_name,a.status from v$asm_client a, v$asm_diskgroup b
where a.group_number=b.group_number and b.name='LH_TEST';
srvctl status database -db cdb1
alter diskgroup LH_TEST dismount;
alter diskgroup LH_TEST mount restricted;
alter diskgroup LH_TEST rename disk 'LH_TEST_0001' to 'LH_TEST_01';
alter diskgroup LH_TEST rename disk 'LH_TEST_0000' to 'LH_TEST_00';
srvctl start database -d cdb1 -o open
select inst_id,name,state from gv$asm_diskgroup where name='LH_TEST';