CreateVolume#

Description#

Creates a volume that can be attached to an instance in the same Availability Zone.

Request Parameters#

Required parameters#

  • AvailabilityZone — The availability zone.

    • Type: String

    • Required: Yes

    • Valid values: ru-msk-vol51 | ru-msk-comp1p | ru-msk-vol52

Optional parameters#

  • Iops — The number of I/O operations per second.

    • Type: Integer

    • Required: No

    • Valid values: Available for the type io2

    • Restriction: For io2 disks only

  • Size — The size of the volume, GiB.

    • Type: Integer

    • Required: No

  • snapshotId — The ID of the snapshot.

    • Type: String

    • Required: No

  • TagSpecification.N — The tags assigned to the resource when it is created.

  • VolumeType — The type of the volume.

    • Type: String

    • Required: No

    • Valid values: st2 | gp2 | io2

    • Default value: st2

Response Elements#

  • availabilityZone — The availability zone of the volume.

    • Type: String

  • createTime — The time when volume was created.

    • Type: Timestamp

  • iops — The number of I/O operations per second that are provisioned for the volume.

    • Type: Integer

  • requestId — The request ID

    • Type: String

  • status — The state of the volume.

    • Type: String

  • tagSet — Tags related to the volume.

    • Type: List of Tag objects

  • volumeId — The ID of the volume

    • Type: String

  • volumeType — The type of the volume.

    • Type: String

Examples#

c2-ec2 CreateVolume AvailabilityZone ru-msk-vol51 Size 32

c2-ec2 CreateVolume AvailabilityZone ru-msk-vol51 Size 32 VolumeType io2 Iops 1600

c2-ec2 CreateVolume AvailabilityZone ru-msk-vol51 Size 32 TagSpecification.0.ResourceType "volume" \
                    TagSpecification.0.Tag.0.Key "tag_key" TagSpecification.0.Tag.0.Value "tag_value"