Databases Reference
In-Depth Information
Let's manually rebalance our DATA_CM01 disk group and see if we can get the 1.8% number closer to zero. After
rebalancing the disk group, the script in Listing 9-11 will display the extent imbalance variance.
SQL> alter diskgroup data_cm01 rebalance power 11;
Diskgroup altered.
SQL>
Listing 9-11. lst09-11-asm-extentbal-variance.sql
SQL> select distinct name,
round(100*((maxfpd-minfpd)/maxfpd),2) var2
from (
select dg.name,
dg.total_mb tpdg,
dg.free_mb fpdg,
d.total_mb tpd,
d.free_mb fpd,
max(d.total_mb) over (partition by dg.name) maxtpd,
min(d.total_mb) over (partition by dg.name) mintpd,
max(d.free_mb) over (partition by dg.name) maxfpd,
min(d.free_mb) over (partition by dg.name) minfpd
from v$asm_diskgroup dg, v$asm_disk d
where dg.group_number=d.group_number
and dg.name='DATA_CM01')
/
Extent imbalance
Disk Group variance
---------- ---------------------
DATA_CM01 .89
SQL>
As we can see, rebalancing the ASM disk group yielded a lower variance in free space.
Measuring Your ASM Partner Disk Balance
Now, measure the ASM partner disk balance using the script in Listing 9-12. Ideally, you would have a near perfect
balance of ASM partner disk counts and partner disk sizes to the primary disks that make up an ASM disk group.
Listing 9-12. lst09-12-asm-partnerdisk-balance.sql
SQL> select
g.name "Diskgroup",
max(p.cnt)-min(p.cnt)
"PImbalance",
100*(max(p.pspace)-min(p.pspace))/max(p.pspace)
"SImbalance",
count(distinct p.fgrp) "FailGrpCnt",
 
Search WWH ::




Custom Search