Creating volumes

While it is convenient to create desired volumes while creating a target group, you can also do this at any time afterwards.

Prerequisites

To create a volume

Admin panel

  1. Open Storage services > Block storage > Volumes, and then click Create volume.
  2. In the Create volume window, enter a volume name and specify a size in gigabytes. Note that volumes can be extended later but not shrunk.
  3. Select a storage tier, failure domain, and redundancy scheme. To benefit from high availability, select a scheme other than No redundancy and failure domain other than Disk.

    If the desired encoding mode is not listed, you can create a custom scheme by specifying the number of data fragments and parity fragments used for recovery. For more details, refer to Redundancy modes.

  4. Click Create.

Command-line interface

Use the following command:

vinfra service block-storage volume create --size <size> --tier {0,1,2,3} (--replicas <norm> | --encoding <M>+<N>)
                                           --failure-domain {0,1,2,3,4} <name>
--size <size>
Volume size, in bytes
--tier {0,1,2,3}
Storage tier
--encoding <M>+<N>

Storage erasure encoding mapping in the format:

  • M: number of data blocks
  • N: number of parity blocks

To see a full list of available redundancy schemes, run the vinfra cluster storage-redundancies command.

--failure-domain {0,1,2,3,4}
Storage failure domain
--replicas <norm>

Storage replication mapping in the format:

  • norm: the number of replicas to maintain
<name>
Volume name

For example, to create the volume vol1 with the size of 100 GiB, the 3 replicas redundancy mode on tier 0 and the failure domain host, run:

# vinfra service block-storage volume create vol1 --size 107374182400 --tier 0 --replicas 3 --failure-domain 1

The created volume will appear in the vinfra service block-storage volume list output:

# vinfra service block-storage volume list
+------------------+--------------+------+--------------+-----------+----------+--------+-----+
| id               | serial       | name | size         | used_size | grp_name | grp_id | lun |
+------------------+--------------+------+--------------+-----------+----------+--------+-----+
| 9841d72f-5d68<…> | cd96cf1031b6 | vol1 | 107374182400 | 1048576   |          |        |     |
+------------------+--------------+------+--------------+-----------+----------+--------+-----+