To drop disks from a disk group, use the DROP
DISK
clause of the ALTER DISKGROUP
statement. You can also drop all of the disks in specified failure groups using the DROP
DISKS
IN
FAILGROUP
clause.
When a disk is dropped, the disk group is rebalanced by moving all of the file extents from the dropped disk to other disks in the disk group. A drop disk operation might fail if not enough space is available on the other disks. The best approach is to perform both the add and drop operation with the same ALTER
DISKGROUP
statement. This has the benefit of rebalancing data extents only one time and ensuring that there is enough space for the rebalance operation to succeed.
The ALTER
DISKGROUP
...
DROP
DISK
SQL statement returns to SQL prompt before the drop and rebalance operations are complete. Do not reuse, remove, or disconnect the dropped disk until the HEADER_STATUS
column for this disk in the V$ASM_DISK
view 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.
If you specify the FORCE
clause for the drop operation, the disk is dropped even if Oracle ASM cannot read or write to the disk. You cannot use the FORCE
flag when dropping a disk from an external redundancy disk group.
A DROP
FORCE
operation leaves data at reduced redundancy until the subsequent rebalance operation completes. This increases your exposure to data loss if there is a subsequent disk failure during rebalancing. Use DROP
FORCE
with caution.
You can also drop disks from a disk group with ASMCA. Refer to "Managing Disk Groups with ASMCA".
The statements in Example 4-6 demonstrate how to drop disks from the disk group data1
described in "Using the ALTER DISKGROUP SQL Statement to Add Disks to a Disk Group ". The first example drops diska5
from disk group data1
. The second example drops diska5
from disk group data1
, and also illustrates how multiple actions are possible with one ALTER DISKGROUP
statement.