hitachivantara.vspone_block.vsp.hv_vsp_one_volume module – Manages volumes on VSP E series, VSP One Block 20 series, and VSP One Block 80 series storage systems.
Note
This module is part of the hitachivantara.vspone_block collection (version 4.6.1).
You might already have this collection installed if you are using the ansible package.
It is not included in ansible-core.
To check whether it is installed, run ansible-galaxy collection list.
To install it, use: ansible-galaxy collection install hitachivantara.vspone_block.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: hitachivantara.vspone_block.vsp.hv_vsp_one_volume.
New in hitachivantara.vspone_block 4.2.0
Synopsis
This module enables creation, modification, and deletion of volumes, as well as attaching and detaching to servers.
Supports various volume operations depending on the specified state parameter.
Utilizes the Hitachi Virtual Storage Platform One Simple API for volume management across VSP One B20 series, VSP One B80 series, and VSP E series models.
For usage examples, visit https://github.com/hitachi-vantara/vspone-block-ansible/blob/main/playbooks/vsp_direct/vsp_one_volume.yml
Requirements
The below requirements are needed on the host that executes this module.
python >= 3.9
Parameters
Parameter |
Comments |
|---|---|
Information required to establish a connection to the storage system. |
|
IP address or hostname of the storage system. |
|
Token used to operate on locked resources. |
|
Password for authentication. This is a required field. |
|
Username for authentication. This is a required field. |
|
Configuration parameters for the volume operation. |
|
Volume size specification. Required for the Create a volume with capacity and pool ID /Create volume with data reduction sharing enabled /Create a single volume with QoS threshold settings (threshold) /Expand the volume size of an existing volume tasks. |
|
Data reduction function configuration. Required for the Create volume with data reduction sharing enabled /Update the Volume saving settings and compression_acceleration of an existing volume tasks. Choices:
|
|
Controls compression acceleration feature. Required for the Update the Volume saving settings and compression_acceleration of an existing volume task. Choices:
|
|
Activates data reduction sharing functionality. Required for the Create volume with data reduction sharing enabled task. Choices:
|
|
Quantity of volumes to create. Required for the Create multiple volumes with custom nickname sequence task. Default: |
|
Storage pool identifier. Required for the Create a volume with capacity and pool ID /Create multiple volumes with custom nickname sequence /Create volume with data reduction sharing enabled /Create a single volume with QoS threshold settings (threshold) tasks. |
|
Quality of service configuration for the volume. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume /Change the alert QoS settings of an existing volume tasks. |
|
QoS alert configuration. Required for the Change the alert QoS settings of an existing volume task. |
|
Activates lower threshold alerts. Required for the Change the alert QoS settings of an existing volume task. Choices:
|
|
Activates response time alerts. Required for the Change the alert QoS settings of an existing volume task. Choices:
|
|
Activates upper threshold alerts. Required for the Change the alert QoS settings of an existing volume task. Choices:
|
|
Permitted duration for lower threshold alerts. Required for the Change the alert QoS settings of an existing volume task. |
|
Permitted duration for response time alerts. Required for the Change the alert QoS settings of an existing volume task. |
|
Permitted duration for upper threshold alerts. Required for the Change the alert QoS settings of an existing volume task. |
|
QoS threshold configuration. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. |
|
Activates minimum IOPS restriction. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. Choices:
|
|
Activates minimum transfer rate restriction. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. Choices:
|
|
Activates response priority setting. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. Choices:
|
|
Activates maximum IOPS restriction. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. Choices:
|
|
Activates maximum transfer rate restriction. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. Choices:
|
|
Minimum IOPS threshold. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. |
|
Minimum transfer rate threshold. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. |
|
Response priority level. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. |
|
Maximum IOPS threshold. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. |
|
Maximum transfer rate threshold. Required for the Create a single volume with QoS threshold settings (threshold) /Change the threshold QoS settings of an existing volume tasks. |
|
Collection of server identifiers for volume attachment. Required for the Attach volume to servers /Detach volume from servers /Attach multiple volumes to a multiple servers in one operation tasks. |
|
Volume identifier. Required for the Attach volume to servers /Detach volume from servers /Change the threshold QoS settings of an existing volume /Change the alert QoS settings of an existing volume /Expand the volume size of an existing volume /Change the nickname the Volume settings of an existing volume /Update the Volume saving settings and compression_acceleration of an existing volume /Delete volume by volume ID tasks. |
|
Collection of volume identifiers for batch operations to add servers. Required for the Attach multiple volumes to a multiple servers in one operation task. |
|
Naming configuration for the volume. Required for the Create a volume with capacity and pool ID /Create multiple volumes with custom nickname sequence /Create volume with data reduction sharing enabled /Create a single volume with QoS threshold settings (threshold) /Change the nickname the Volume settings of an existing volume tasks. |
|
Foundation name for volume naming. Required for the Create a volume with capacity and pool ID /Create multiple volumes with custom nickname sequence /Create volume with data reduction sharing enabled /Create a single volume with QoS threshold settings (threshold) /Change the nickname the Volume settings of an existing volume tasks. |
|
Digit count for the numerical portion of volume names. Required for the Create multiple volumes with custom nickname sequence task. |
|
Initial number for volume name sequencing. Required for the Create multiple volumes with custom nickname sequence task. |
|
Defines the volume operation type. Available options include Choices:
|
Attributes
Attribute |
Support |
Description |
|---|---|---|
Support: none |
Specifies whether the module operates in check mode. |
Examples
- name: Create a volume with capacity and pool_id
hitachivantara.vspone_block.vsp.hv_vsp_one_volume:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
capacity: 1GB
pool_id: 1
- name: Create multiple volumes with custom nickname sequence
hitachivantara.vspone_block.vsp.hv_vsp_one_volume:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
number: 3
volume_name:
base_name: "DataVol"
start_number: 10
number_of_digits: 3
pool_id: 2
- name: Create volume with data reduction sharing enabled
hitachivantara.vspone_block.vsp.hv_vsp_one_volume:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
capacity: 200MB
is_data_reduction_share_enabled: true
pool_id: 3
- name: Update volume with QoS threshold settings
hitachivantara.vspone_block.vsp.hv_vsp_one_volume:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
volume_id: 12
qos_settings:
threshold:
is_upper_iops_enabled: true
upper_iops: 5000
is_lower_iops_enabled: true
lower_iops: 1000
is_upper_transfer_rate_enabled: true
upper_transfer_rate: 200
is_lower_transfer_rate_enabled: false
is_response_priority_enabled: true
response_priority: 2
- name: Attach volume to servers
hitachivantara.vspone_block.vsp.hv_vsp_one_volume:
state: attach_server
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
volume_id: 1234
server_ids:
- "server-01"
- "server-02"
- name: Detach volume from servers
hitachivantara.vspone_block.vsp.hv_vsp_one_volume:
state: detach_server
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
volume_id: 1234
server_ids:
- "server-01"
- name: Create volume with data reduction setting
hitachivantara.vspone_block.vsp.hv_vsp_one_volume:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
capacity: 120GB
pool_id: 5
capacity_saving: "deduplication_and_compression"
- name: Delete volume by volume_id
hitachivantara.vspone_block.vsp.hv_vsp_one_volume:
state: absent
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
volume_id: 1234
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
|---|---|
Information of the volume object. Returned: always |
|
Capacity saving setting (e.g., DISABLE). Returned: success |
|
Capacity saving status. Returned: success |
|
Whether compression acceleration is enabled. Returned: success |
|
Compression acceleration status. Returned: success |
|
Free capacity of the volume. Returned: success |
|
Free capacity in MB. Returned: success |
|
ID of the volume. Returned: success |
|
ID of the volume in hexadecimal. Returned: success |
|
Whether data reduction share is enabled. Returned: success |
|
List of LUNs associated with the volume. Returned: success |
|
Nickname of the volume. Returned: success |
|
Number of servers connected to the volume. Returned: success |
|
Number of snapshots for the volume. Returned: success |
|
ID of the pool. Returned: success |
|
Name of the pool. Returned: success |
|
QoS settings for the volume. Returned: success |
|
Reserved capacity of the volume. Returned: success |
|
Total capacity of the volume. Returned: success |
|
Total capacity in MB. Returned: success |
|
Used capacity of the volume. Returned: success |
|
Used capacity in MB. Returned: success |
|
List of volume types. Returned: success |