Important ASM Commands and Concepts
Rebalancing Disks
When you drop/remove a disk from the diskgroup, it is important to apply the proper value for the power setting for rebalance and to use the WAIT
command.
Example ASM Command:
SQL> ALTER DISKGROUP <DiskGroupName> DROP DISK <diskName> REBALANCE POWER 8 WAIT;
-
The rebalance command moves the data off of the disk that you are removing from the diskgroup, distributing the data across the remaining DISKS.
-
The power setting is a number from 1 to 11. It determines how much processing power is dedicated to the rebalance, versus normal operations. Unless the encrypting occurs during heavy traffic volume, the minimum value you should use is 6. Otherwise, consult the customer’s DBA for the proper setting. An appropriate value to start with is 8.
Mapping Raw Devices
You can map raw devices for this configuration using:
-
EMC PowerPath
If using EMC PowerPath then the device names are similar to the following:
/dev/hdiskpowerXX
.When browsing the CipherTrust Manager through the local host, you cannot find Power Path devices. You must manually input the paths. The guarded disk names are prepended with:
/dev/secvm
.
Checking Rebalance Status
The wait
command is very important when ASM performs a rebalance. When you specify wait
, the command prompt does not display until all of the data is rebalanced and migrated off of the disk. If you do not specify wait, the command prompt returns immediately, and you must issue the following ASM command to check the status of the rebalance:
SQL> select * from v$asm_operation;
This command returns information about the:
-
State
-
Current power level
-
Current amount rebalanced
-
Estimated work until completion
-
Rate
-
Estimated minutes
-
Any error codes
It is highly recommended that you always specify the wait
command when performing a Drop Disk with Rebalance. If it is not specified, ASM may prematurely release the disk, thereby allowing CTE to place a GuardPoint on the disk before the rebalance completes. This action may corrupt the data.
Oracle cautions against this issue:
The ALTER DISKGROUP...DROP DISK
statement returns before the drop and rebalance operations complete. Do not reuse, remove, or disconnect the dropped disk until the HEADER_STATUS
column in the V$ASM_DISK
view for this disk changes to FORMER
. You can query the V$ASM_OPERATION
view to determine the amount of time remaining for the drop/rebalance operation to complete. For more information, refer to the Oracle Database SQL Language Reference and the Oracle Database Reference.