mkvolume

Use the mkvolume command to create an empty volume from existing storage pools. You can use this command for high availability configurations that include HyperSwap®, but it can also be used for volumes that are not high availability.

Syntax

mkvolume [ namename ] sizedisk_size [ -unit { b | kb | mb | gb | tb | pb } ] [ -iogrp { iogroup_id | iogroup_name } ] -pool { storage_pool_id | storage_pool_name } [ -cache { none | readonly | readwrite } ] [ { -thin | -compressed } ] [ -buffersize { buffer_size | buffer_percentage% } ] [ -warning { warning_capacity | warning_percentage% } ] [ -noautoexpand ] [ -grainsize { 32 | 64 | 128 | 256 } ] [ -udidudid ]

Parameters

-namename
(Optional) Specifies the name that is used for the volume that is created. This value must be an alphanumeric string 1 - 63 characters.
Remember: If you do not specify -name, a unique default name such as volume1 is used.
-sizedisk_size
(Required) Specifies the capacity of the volume, which is used with the value of the unit. The default capacity is in MB. When the unit of bytes is used, all capacities must be in multiples of 512 bytes. An entire extent is reserved even if it is only partially used.
-unitb | kb | mb | gb | tb | pb
(Optional) Specifies the data units to use with the capacity that is specified by the -size parameter. The default unit type is mb.
-iogrpiogroup_id_list | iogroup_name_list
(Optional) Specifies the I/O group that the new volume is cached in. The value can be a colon-separated list of up to two I/O group IDs or names. If no value is specified, the caching I/O group is selected based on the storage pool site. If you do not specify the -iogrp parameter, the caching I/O group is selected by the system.
Important: If two I/O groups are specified, they must be in different sites, and the storage pools that are specified must be in different sites. The order of the sites must correspond.

If you create a HyperSwap volume, the caching I/O groups are selected based on the sites of the storage pools.

-poolstorage_pool_id_list | storage_pool_name_list
(Required) Specifies the storage pool in which to create the new volume. The value must be a colon-separated list of up to two storage pool IDs or names.
Note: If one storage pool is specified, a basic volume is created with one copy.

On systems with standard topology, a mirrored volume can be created by specifying two storage pools.

On systems with a hyperswap topology, a highly available volume can be created by specifying two storage pools in different sites.

-cachenone | readonly | readwrite
(Optional) Specifies the caching options for the volume. Use one of the following valid entries:
  • readwrite enables the cache for the volume (default)
  • readonly disables write caching but allows read caching for a volume
  • none disables the cache mode for the volume
-thin
(Optional) Specifies that the volume is to be created with thin-provisioning. You cannot specify this parameter with -compressed. If you do not specify -thin or -compressed, the volume that is created is fully allocated.
-compressed
(Optional) Specifies that the volume is to be created compressed. If the -iogrp parameter is not specified, the least used I/O group is used for compressed copies (considering the subset of I/O groups that support compression).
Remember: This command fails if no I/O groups support compression. If there are two sites, both sites must have at least one I/O group that supports compression.

You cannot specify this parameter with -thin. If you do not specify -thin or -compressed, the volume that is created is fully allocated.

-buffersizebuffer_size | buffer_percentage
(Optional) Specifies the pool capacity the volume attempts to reserve as a buffer for thin-provisioned and compressed volumes. You must specify either -thin or -compressed with this parameter. The default value is 2%.
-warningwarning_capacity | warning_percentage
(Optional) Specifies a threshold at which a warning error log is generated for volumes. A warning is generated when the used disk capacity on the thin-provisioned volume exceeds the specified threshold. You must specify either -thin or -compressed with this parameter. The default value is 80%.
-noautoexpand
(Optional) Specifies that the volume not automatically expand as it is written to. The available buffer capacity decreases as the used capacity increases. The volume copy goes offline if the buffer capacity is fully used. The buffer capacity can be increased by specifying expandvdisksize -rsize. You must specify either -thin or -compressed with this parameter. If you do not specify -noautoexpand, the volume automatically expands as it is written to.
-grainsize32 | 64 | 128 | 256
(Optional) Sets the grain size (KB) for a thin-provisioned volume. If you are using the thin-provisioned volume in a FlashCopy map, use the same grain size as the map grain size for best performance. If you are using the thin-provisioned volume directly with a host system, use a small grain size. The grain size value must be 32, 64, 128, or 256 KB. The default is 256 KB.
-udidudid
(Optional) Specifies the unit number udid for the volume.
Important: The udid is an identifier that is required to support OpenVMS hosts (no other systems use this parameter).
Valid options are a decimal number from 0 through 32767, or a hexadecimal number from 0 through 0x7FFF. A hexadecimal number must be preceded by 0x (for example, 0x1234).

Description

This command creates an empty volume, which is a formatted (zeroed) volume, by using storage from existing storage pools. You can also create a highly available volume on systems with hyperswap topology.

Use the mkimagevolume command to create a new volume by importing existing data on a managed disk.

An invocation example to create a volume in storage pool 0

mkvolume -pool 0 -size 1000

The detailed resulting output:

Volume, id [0], successfully created.

An invocation example to create a HyperSwap volume with a hyperswap topology

mkvolume -pool site1pool:site2pool -size 200

The detailed resulting output:

Volume, id [2], successfully created.