mkvdisk
Use the mkvdisk command to create sequential,
striped, or image mode volume objects. When they are mapped to a host object, these objects are
seen as disk drives with which the host can run I/O operations. Note the first syntax diagram
below is for striped or sequential volumes and the second syntax diagram is for image mode
volumes. Use the mkvolume command for a simplified way of creating high
availability volumes. It includes stretched and
hyperswap topologies. Use the mkimagevolume
command for a simplified way of creating an image mode volume, importing existing data from a
managed disk.
Syntax
Parameters
- (Required) Specifies one or more storage pools to use when you are creating this volume. If you are creating multiple copies, you must specify one storage pool per copy. The primary copy is allocated from the first storage pool in the list.
- (Optional) Specifies the unit number udid for the disk. The udid is an identifier that is required to support OpenVMS hosts; no other systems use this parameter. Valid options are a decimal number 0 - 32 767, or a hexadecimal number 0 - 0x7FFF. A hexadecimal number must be preceded by 0x (for example, 0x1234).
- (Optional) Specifies the virtualization type. When you create sequential or image mode
volumes, you must also specify the -mdisk parameter. You cannot use
-vtype seqor-vtype imagein a data reduction pool. The default virtualization type is striped. - (Optional) Specifies the I/O group (node pair) with which to associate this volume. If you
specify -node, you must also specify -iogrp.Remember:
- Create the first compressed volume copy for an I/O group to activate compression.
- You cannot create or move a volume copy that is compressed to an I/O group that contains at least one node that does not support compressed volumes. You must select another I/O group to move the volume copy to (but it does not affect moving to the recovery I/O group).
- (Optional) Specifies the members of the volume I/O group access set. If this option is not specified, only the caching I/O group is added to the volume I/O group access set. If this option is specified, then the -iogrp option must also be specified and the I/O group access set must include the I/O group that is specified by the -iogrp parameter.
- (Required for sequential or striped volume creation) (Optional for image volume creation) Specifies the capacity of the volume, which is used with the value of the unit. All capacities, including changes, must be in multiples of 512 bytes. An error occurs if you specify a capacity that is not a multiple of 512. It can only happen when byte units (-b) are used. However, an entire extent is reserved even if it is only partially used. The default capacity is in MB. You can specify a capacity of 0. Specify the size in bytes in multiples of logical block address (LBA) sizes.
- (Optional) Specifies that the volume be formatted. This parameter is no longer required for
any volumes.This parameter is not required when you create standard-provisioned volumes. The format operation is automatically applied to standard-provisioned volumes unless you specify -nofmtdisk parameter. The format operation sets the extents that make up this volume to all zeros after it is created. This process takes place in the background concurrently with host I/O operations on the new volume.Remember: Formatting is on by default for single copy, standard-provisioned, and non-image mode volumes. You cannot format an image mode volume.
The format operation completes asynchronously. You can query the status by using the lsvdiskprogress command. You cannot specify this parameter with the -vtype image parameter.
This parameter is not required when you create thin-provisioned volumes. Thin-provisioned volumes return zeros for extents that are not written to. No format operation is required. This parameter also synchronizes mirrored copies by default.
- (Optional) Specifies that formatting be turned off for the new volume.Remember: Formatting is on by default for single copy, standard-provisioned, and non-image mode volumes, and you can specify this parameter to turn it off.
- (Optional) Defines how much physical space is initially allocated to the thin-provisioned
or compressed volume. This parameter makes the volume thin-provisioned; otherwise, the volume
is standard-provisioned. Specify the disk_size |
disk_size_percentage value by using an integer, or an integer immediately followed
by the percent character (%). Specify the units for a
disk_size integer by using the -unit parameter; the
default is MB. The -rsize value can be greater than, equal to, or less
than the size of the volume. The auto option creates a volume copy that
uses the entire size of the MDisk.
If you specify the -rsize auto option, you must also specify the -vtype image option. If you specify -import you must specify -rsize.
If the volume is in a data reduction storage pool, the value of the -rsize parameter will be ignored in mkvdisk. Only its presence or absence is used to determine whether the disk is a data reduction volume copy or a thick volume copy.
- (Optional) Requires that the -rsize parameter also be specified.
Specifies a threshold at which a warning error log is generated for volume copies. A warning
is generated when the used disk capacity on the thin-provisioned copy first exceeds the
specified threshold. Note: You cannot specify this parameter for thin-provisioned or compressed volumes that are in data reduction pools.You can specify a disk_size integer, which defaults to MBs unless the -unit parameter is specified. Or you can specify a disk_size%, which is a percentage of the volume size.Important: If -autoexpand is:To disable warnings, specify
- Enabled, the default value for -warning is 80% of the volume capacity.
- Not enabled, the default value for -warning is 80% of the real capacity.
0. - (Optional) Specifies that thin-provisioned copies automatically expand their real
capacities by allocating new extents from their storage pool. Requires that the
-rsize parameter also be specified. If the
-autoexpand parameter is specified, the -rsize
parameter specifies a capacity that is reserved by the copy. It protects the copy from going
offline when its storage pool runs out of space by having the storage pool to consume this
reserved space first.
The parameter has no immediate effect on image mode copies. However, if the image mode copy is later migrated to managed mode, the copy is then automatically expanded.
- (Optional) Sets the grain size (KB) for a thin-provisioned volume. This parameter also
requires that the -rsize parameter be specified. 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.
If the volume to be created is a thin-provisioned volume in a data reduction storage pool, the -grainsize parameter cannot be used. This type of volume will be created with a grain size of 8 KB.
- (Optional) Creates a deduplicated volume. If you specify
-deduplicated, you must also specify -rsize because
it applies only to thin-provisioned or compressed volumes. Note: Data deduplication works only with data reduction storage pools. You can only create deduplicated volumes and volume copies in an I/O group if there are no compressed volumes or volume copies in regular storage pools.
- (Optional) Enables compression for the volume. This parameter must be specified with -rsize and cannot be specified with -grainsize.
- (Optional) Imports a thin-provisioned volume from the MDisk. If you specify -import you must also specify -rsize.
- (Optional) Specifies the number of copies to create. The num_copies value can be 1 or 2. Setting the value to 2 creates a mirrored volume. The default value is 1.
- (Optional) Creates copies in sync. Use this parameter if you have already formatted the MDisks, or when read stability to unwritten areas of the volume is not required.
- (Optional) Specifies the copy synchronization rate. A value of zero (0) prevents synchronization. The default value is 50. See Table 2 for the supported -syncrate values and their corresponding rates. Use this parameter to alter the rate at which the standard-provisioned volume or mirrored volume format before synchronization.
- (Optional) Specifies how to configure the mirror write algorithm priority. If not
specified, the default value is latency.
- Choosing latency means a copy that is slow to respond to a write input/output (I/O) becomes unsynchronized, and the write I/O completes if the other copy successfully writes the data.
- Choosing redundancy means a copy that is slow to respond to a write I/O synchronizes completion of the write I/O with the completion of the slower I/O to maintain synchronization.
- (Optional) Specifies one or more managed disks. For sequential and image mode volumes, the
number of MDisks must match the number of copies. For sequential mode volumes, each MDisk must
belong to the specified storage pool. For striped volumes, you cannot specify the
-mdisk parameter if the -copies value is greater
than 1.
When you create a single copy striped volume, you can specify a list of MDisks to stripe across.
You must use this parameter to specify an MDisk that has a mode of
unmanaged. - (Optional) Specifies the preferred node ID or the name for I/O operations to this volume.
You can use the -node parameter to specify the preferred access node. If you specify -node, you must also specify
-iogrp.
Note: This parameter is evaluated by multipath device drivers. The system chooses a default if you do not supply this parameter.
- (Optional) Specifies the data units to use along with the capacity that is specified by the -size and -rsize parameters. The default unit type is MB.
- (Optional) Specifies a name to assign to the new volume.
- (Optional) Specifies the caching options for the volume. Valid entries are:
- readwrite enables the cache for the volume.
- readonly disables write caching while allowing read caching for a volume.
- none disables the cache mode for the volume.
The default is readwrite.
- (Optional) Specifies the MDisk tier when an image mode copy is added. This
parameter is valid only when -vtype is image.
- tier0_flash
- Specifies a
tier0_flashhard disk drive or an external MDisk for the newly discovered or external volume. - tier1_flash
- Specifies an
tier1_flash(or flash drive) hard disk drive or an external MDisk for the newly discovered or external volume. - tier_enterprise
- Specifies a
tier_enterprisehard disk drive or an external MDisk for the newly discovered or external volume. - tier_nearline
- Specifies a
tier_nearlinehard disk drive or an external MDisk for the newly discovered or external volume. - tier_scm
- Specifies a
tier_scmhard disk drive or an external MDisk for the newly discovered or external volume.
- ssd
- Specifies an SSD (or flash drive) hard disk drive or an external MDisk for the newly discovered or external volume.
- nearline
- Specifies a nearline hard disk drive or an external MDisk for the newly discovered or external volume.
- enterprise
- Specifies an enterprise hard disk drive or an external MDisk for the newly discovered or external volume.
Note: This action applies to both copies if you are creating a mirrored volume with two image mode copies by using this command. - Determines whether the IBM®
Easy Tier® function is allowed to move extents for
this volume. Note: The -easytier parameter must be followed by either on or off:
- If set to on, then Easy Tier functions are active.
- If set to off, then Easy Tier functions are inactive.
If the Easy Tier feature is enabled, and if a volume copy is striped and not being migrated, the following table applies.
Table 1. Easy Tier settings for storage pools and volumes Storage pool Easy Tier setting Number of tiers in the storage pool Volume copy Easy Tier setting Volume copy Easy Tier status Off One Off inactive (see note 1) Off One On inactive (see note 1) Off Two Off inactive (see note 1) Off Two On inactive (see note 1) Measure One Off measured (see note 2) Measure One On measured (see note 2) Measure Two Off measured (see note 2) Measure Two On measured (see note 2) Auto One Off measured (see note 2) Auto One On balanced (see note 3) Auto Two Off measured (see note 2) Auto Two On active (see note 4) On One Off measured (see note 2) On One On balanced (see note 3) On Two Off measured (see note 2) On Two On active (see note 4) Notes:- When the volume copy status is inactive, no Easy Tier functions are enabled for that volume copy.
- When the volume copy status is measured, the Easy Tier function collects usage statistics for the volume but automatic data placement is not active.
- When the volume copy status is balanced, the Easy Tier function enables performance-based pool balancing for that volume copy.
- When the volume copy status is active, the Easy Tier function operates in automatic data placement mode for that volume.
If the volume copy is in image or sequential mode or is being migrated, the volume copy Easy Tier status is measured instead of active.
The default Easy Tier setting for a storage pool is auto, and the default Easy Tier setting for a volume copy is on. It means that Easy Tier functions except pool performance balancing are disabled for storage pools with a single tier, and that automatic data placement mode is enabled for all striped volume copies in a storage pool with two or more tiers.
Description
You must decide which storage pool or storage pools provide the storage for the volume. Use the lsmdiskgrp command to list the available storage pools and the amount of free storage in each pool. If you are creating a volume with more than one copy, each storage pool that you specify must have enough space for the size of the volume.
If you create a thin-provisioned or compressed volume from a data reduction storage pool, that volume uses the same properties as the data reduction storage pool. You can create standard-provisioned volumes from data reduction pools, but these volumes use different data reduction properties.
- Not be in sequential or image mode.
- Not have a warning threshold set (using -warning).
- Use
-cache readwritewhen caching. - Have -autoexpand enabled.
A compressed volume in a data reduction pool can only be created in an I/O group with V5030, V7000, or SVC node types. Thin provisioned volumes can be created on any node type.
No restriction exists for the number of compressed volumes within a data reduction storage pool.
An encryption key cannot be used when you create an image mode MDisk. To use encryption (when the MDisk has an encryption key), the MDisk must be self-encrypting.
- sequential (seq)
- This virtualization type creates the volume that uses sequential extents from the specified MDisk (or MDisks, if creating multiple copies). The command fails if there are not enough sequential extents on the specified MDisk.
- striped
- The default virtualization type. If the -vtype parameter is not
specified, striped is the default; all managed disks in the storage pool
are used to create the volume. The striping is at an extent level; one extent from each
managed disk in the group is used. For example, a storage pool with 10 managed disks uses one
extent from each managed disk. It then uses the 11th extent from the first managed disk, and
so on.
If the -mdisk parameter is also specified, you can supply a list of managed disks to use as the stripe set. It can be two or more managed disks from the same storage pool. The same circular algorithm is used across the striped set. However, a single managed disk can be specified more than once in the list. For example, if you enter
-mdisk 0:1:2:1, the extents are from the following managed disks: 0, 1, 2, 1, 0, 1, 2, and so forth. All MDisks that are specified in the -mdisk parameter must be in the managed mode.A capacity of 0 is allowed.
- image
- This virtualization type allows image mode volumes to be created when a managed disk
already has data on it, perhaps from a previrtualized subsystem. When an image mode volume is
created, it directly corresponds to the (previously unmanaged) managed disk that it was
created from. Therefore, except for thin-provisioned image mode volumes, volume logical block
address (LBA) x equals managed disk LBA x. You can use
this command to bring a nonvirtualized disk under the control of the system. After it is
under the control of the system, you can migrate the volume from the single managed disk.
When it is migrated, the volume is no longer an image mode volume. You can add image mode volumes to an already populated storage pool with other types of volumes, such as a striped or sequential.Important: An image mode volume must be 512 bytes or greater. At least one extent is allocated to an image mode volume.Remember: If you create a mirrored volume from two image mode MDisks without specifying a -size value, the capacity of the resulting volume is the smaller of the two MDisks, and the remaining space on the larger MDisk is not accessible.
- Do not create a volume in an offline I/O group. You must ensure that the I/O group is online before you create a volume to avoid any data loss. This action applies in particular to re-creating volumes that are assigned the same object ID.
- To create an image mode disk, you must already have a quorum disk present in the system because an image mode disk cannot be used to hold quorum data. Refer to information on quorum disk creation for more details.
- The command fails if either limit of 2048 volumes per I/O Group or 8192 volume copies per system is reached.
| User-specified syncrate attribute value | Data copied/sec |
|---|---|
| 1 - 10 | 128 KB |
| 11 - 20 | 256 KB |
| 21 - 30 | 512 KB |
| 31 - 40 | 1 MB |
| 41 - 50 | 2 MB |
| 51 - 60 | 4 MB |
| 61 - 70 | 8 MB |
| 71 - 80 | 16 MB |
| 81 - 90 | 32 MB |
| 91 - 100 | 64 MB |
An invocation example
mkvdisk -mdiskgrp Group0 -size 0
-iogrp 0 -vtype striped -mdisk mdisk1 -node 1
The resulting output:
Virtual Disk, id [1], successfully created
An invocation example for creating an image mode volume
mkvdisk -mdiskgrp Group0
-iogrp 0 -vtype image -mdisk mdisk2 -node 1
The resulting output:
Virtual Disk, id [2], successfully created
An invocation example for creating a new volume
mkvdisk -mdiskgrp Group0 -size 0 -unit kb
-iogrp 0 -vtype striped -mdisk mdisk1 -node 1 -udid 1234 -easytier off
The resulting output:
Virtual Disk id [2], successfully created
An invocation example for creating a thin-provisioned volume
mkvdisk -mdiskgrp Group0 -iogrp 0 -vtype striped -size 10 -unit gb -rsize 20% -autoexpand -grainsize 32
The resulting output:
Virtual Disk id [1], successfully created
An invocation example for creating a compressed volume copy
mkvdisk -mdiskgrp 0 -iogrp 0 -size 1 -unit tb -rsize 0 -autoexpand -warning 0 -compressed
The resulting output:
Virtual Disk id [1], successfully created
An invocation example for creating a mirrored image-mode volume
mkvdisk -mdiskgrp Group0:Group0 -mdisk mdisk2:mdisk3 -iogrp 0 -vtype image -copies 2
The resulting output:
Virtual Disk id [1], successfully created
An invocation example for creating a mirrored volume
mkvdisk -iogrp 0 -mdiskgrp 0:1 -size 500 -copies 2
The resulting output:
Virtual Disk id [5], successfully created
An invocation example for configuring a mirror write algorithm priority
mkvdisk -mdiskgrp Group0 -iogrp 0 -vtype striped -mirrorwritepriority redundancy -size 500
The resulting output:
Virtual Disk id [5], successfully created
An invocation example to create a disk with default grain size
mkvdisk -iogrp 0 -mdiskgrp 0 -size 100 -rsize 5%
The resulting output:
Virtual Disk id [5], successfully created
An invocation example for creating a volume with I/O groups 0 and 1 in its I/O group access set
mkvdisk -iogrp 0 -mdiskgrp 0 -size 500 -accessiogrp 0:1
The resulting output:
Virtual Disk id [5], successfully created
An invocation example for creating a volume with warning considerations
mkvdisk -mdiskgrp 6 -size 200 -rsize 50 -iogrp 0
The resulting output:
Virtual Disk, id [2], successfully created
...
lsvdisk 2
...
warning 20 # threshold in MB = 50 x 80 / 100 = 40 MB; threshold as %age of volume capacity = 40 / 200 * 100 = 20
...
An invocation example for creating a volume with warning considerations
mkvdisk -mdiskgrp 6 -size 200 -rsize 50 -iogrp 0 -warning 80%
The resulting output:
Virtual Disk, id [2], successfully created
...
lsvdisk 2
...
warning 80 # displayed as %age of volume capacity
...
An invocation example for creating a volume with warning considerations
mkvdisk -mdiskgrp 6 -size 200 -rsize 50 -iogrp 0 -autoexpand
The resulting output:
Virtual Disk, id [2], successfully created
...
lsvdisk 2
...
warning 80 # displayed as %age of volume capacity
...
An invocation example to create a volume with the read cache enabled
mkvdisk -iogrp 0 -size 10 -unit gb -mdiskgrp 0 -cache readonly
The resulting output:
Virtual Disk, id [2], successfully created
An invocation example to create volume Group0
mkvdisk -mdiskgrp Group0 -iogrp io_grp0 -vtype image -mdisk 13 -node 1 -udid 1234 -tier tier_nearline
The resulting output:
Virtual Disk, id [0], successfully created
An invocation example to turn off formatting while creating volume
Burnley1
mkvdisk -mdiskgrp Burnley1 -iogrp 0 -mdiskgrp 0:1 -size 500 -nofmtdisk -copies 2
The resulting output:
Virtual Disk, id [0], successfully created
An invocation example to create a deduplicated volume copy
mkvdisk -mdiskgrp datareductionpool0 -size 100 -unit gb -iogrp 0 -rsize 0 -autoexpand -deduplicated
The resulting output:
Virtual Disk, id [4], successfully created
