Moving a Block Volume to Another Compartment
Move a block volume in the Block Volume service to a different compartment.
When you move a block volume to a new compartment, associated Block Volume resources, such as volume backups, volume clones, and volume replicas aren't moved. After you move the block volume to the new compartment, inherent policies apply immediately and affect access to the block volume through the Console. For more information, see Managing Compartments.
When you move a block volume between compartments, ensure that users have sufficient access permissions on the compartment the block volume is being moved to.
- On the Block Volumes list page, find the volume that you want to work with. If you need help finding the list page or the volumes, see Listing Volumes.
- From the , select Move resource.
- In the Move resource panel, select the destination compartment from the list.
- Select Move resource.
Use the
oci bv volume change-compartment
command and specify the--compartment-id
and--volume-id
parameters to move a block volume to a different compartment:oci bv volume change-compartment --compartment-id <compartment_OCID --volume-id <volume_OCID>
For a complete list of parameters and values for CLI commands, see the CLI Command Reference.
Run the ChangeVolumeCompartment operation and specify the
volumeId
attribute in the request body and thecomparmentId
attribute in the ChangeVolumeCompartmentDetails resource to move a block volume to a different compartment.