302 Implementing the IBM Storwize V7000 with IBM Spectrum Virtualize V8.2.1
7.8.8  Deleting a volume
Use the rmvdisk command to delete a volume. When this command is run on a managed 
mode volume, any data on the volume is lost, and the extents that made up this volume are 
returned to the pool of free extents in the storage pool.
If any remote copy, IBM FlashCopy, or host mappings still exist for the target of rmvdisk 
command, the delete fails unless the -force flag is specified. This flag causes the deletion of 
the volume and any volume to host mappings and copy mappings.
If the volume is being migrated to image mode, the delete fails unless the -force flag is 
specified. Use of -force flag halts the migration and then deletes the volume.
If the command succeeds (without the -force flag) for an image mode volume, the write 
cache data is flushed to the storage before the volume is removed. Therefore, the underlying 
LU is consistent with the disk state from the point of view of the host using the image-mode 
volume (crash-consistent file system). If the -force flag is used, consistency is not ensured; 
that is, data the host believes to be written might not be present on the LU.
If any non-destaged data exists in the fast write cache for the target of rmvdisk command, the 
deletion of the volume fails unless the -force flag is specified, in which case, any 
non-destaged data in the fast write cache is deleted.
Example 7-17 shows how to use the rmvdisk command to delete a volume from your IBM 
Spectrum Virtualize configuration.
Example 7-17   The rmvdisk command
IBM_2145:ITSO_CLUSTER:superuser>rmvdisk volume_A
This command deletes the volume_A volume from the IBM Spectrum Virtualize configuration. 
If the volume is assigned to a host, you must use the -force flag to delete the volume, as 
shown in Example 7-18.
Example 7-18   The rmvdisk -force command 
IBM_2145:ITSO_CLUSTER:superuser>rmvdisk -force volume_A
Tips: Changing the I/O Group with which this volume is associated requires a flush of the 
cache within the nodes in the current I/O Group to ensure that all data is written to disk. I/O 
must be suspended at the host level before you perform this operation.
If the volume has a mapping to any hosts, it is impossible to move the volume to an I/O 
group that does not include any of those hosts.
This operation fails if insufficient space exists to allocate bitmaps for a mirrored volume in 
the target I/O Group.
If the -force parameter is used and the system is unable to destage all write data from the 
cache, the contents of the volume are corrupted by the loss of the cached data.
If the -force parameter is used to move a volume that has out-of-sync copies, a full 
resynchronization is required.