2 - 3 minutes readRebalancing Concep

Reader Mode
• “Rebalancing” is the process of moving file extents onto disks
• Purpose of rebalancing is evenly distributing the I/O load of the diskgroup
• In RAC Environment, Rebalancing for a disk group is done within a single ASM instance only and cannot be distributed across multiple cluster node to speed it up
• ASM will automatically rebalance data on disks when disks are added or removed by using

ASM_POWER_LIMIT initialization parameter.

• ASM_POWER_LIMIT parameter default value is 1
• We can change ASM_POWER_LIMIT parameter values by issuing bellow mention command in run time.

ALTER DISKGROUP REBALANCE [POWER n];

• The POWER value can be from 0 to 11 where 0 stops rebalancing and 11 is the fastest.
• The ASM_POWER_LIMIT can be found in the v$asm_operation view.
• The higher the limit, the faster a rebalance operation may complete. Lower values cause rebalancing to take longer, but consume less processing and I/O resources. This leaves these resources available for other applications, such as the database.

• Rebalancing could be done while the databases (ASM clients, in this case) are connected. However, database performance could be impacted but I think the best recommendation would be when the load on databases are low(off load hours, or non peak work times) and there you can use higher intensity setting(asm_power_limit putting higher for example) without degrading performance of databases significantly

Play with Rebalancing:

Check ASM Disk usage, before creating Database:

SQL> select TOTAL_MB, FREE_MB, FAILGROUP,PATH from v$asm_disk;

TOTAL_MB FREE_MB FAILGROUP PATH
——————————————————————————–
2055 2004 A /dev/rdsk/c0d1s0
2055 2004 B /dev/rdsk/c0d1s1

Check ASM Disk Usage, after creating Database:

SQL> select TOTAL_MB, FREE_MB, FAILGROUP,PATH from v$asm_disk;

TOTAL_MB FREE_MB FAILGROUP PATH
——————————————————————————–
2055 1056 A /dev/rdsk/c0d1s0
2055 1056 B /dev/rdsk/c0d1s1

Now we add 2 GB of Disk in failgroup A

SQL> ALTER DISKGROUP DB_DATA01 add failgroup A DISK ‘/dev/rdsk/c0d1s3’;

Check rebalancing Status:

Select * from v$asm_operation

After rebalancing check the Disk Status:

SQL> select TOTAL_MB, FREE_MB, FAILGROUP,PATH from v$asm_disk;

TOTAL_MB FREE_MB FAILGROUP PATH
——————————————————————————–
2055 1367 A /dev/rdsk/c0d1s0
2055 1367 B /dev/rdsk/c0d1s1
2055 1368 A /dev/rdsk/c0d1s3

Conclusion:
Before Adding disk Capacity of each Disk is 2 GB
Total Space: 4 GB (2GB*2 Disk)
Total Used MB: 1998
Each Disk Used MB: 999

Afterb Adding Disk capacity of each disk is 2 GB
Total Space: 6 GB (2GB*3 Disk)
Total Used: 2063
Each Disk Used MB: 688

We had 2x 2 GB disks that where 1998 MB Used and added 1×2 GB disks, the final set should be 3×2 GB disks with 1998 MB of data balance across them, so each would have 688 MB of data. To me that means, at a minimum, we have to move 311 MB of data.

Related Articles

Responses

Your email address will not be published. Required fields are marked *

Password Reset
Please enter your e-mail address. You will receive a new password via e-mail.