Enabling Cross-Region Replication When Creating a Block Volume
Learn how to enable cross-region replication when you create a new block volume.
See Creating a Volume. Use the
oci bv volume create
command and specify the--compartment-id
,--block-volume-replicas
,"availabilityDomain"
and"xrrKmsKeyId"
parameters to create a block volume with cross-region replication enabled:oci bv volume create --compartment-id <compartment_ID> --block-volume-replicas '[{"displayName":"<display_name>","availabilityDomain":"<availability-domain_ID>","xrrKmsKeyId" : "<kms_key_ID>"}]'
For example:
oci bv volume create --compartment-id ocid1.compartment.oc1.phx.<unique_ID> --block-volume-replicas '[{"displayName":"Sample_Replica","availabilityDomain":"pjBI:US-ASHBURN-AD-1","xrrKmsKeyId" : "ocid1.key.oc1.iad-ad-1.<unique_ID>"}]'
For a complete list of parameters and values for CLI commands, see the CLI Command Reference.
Run the
CreateVolume
operation and specify theblockVolumeReplicas
attribute in theCreateVolumeDetails
resource to enable cross-region replication for a new block volume.