hitachivantara.vspone_block.vsp.hv_vsp_one_volume module – Manages volumes on Hitachi VSP One storage systems.
Note
This module is part of the hitachivantara.vspone_block collection (version 4.2.0).
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 Vantara VSP One Simple API for volume management across VSP one B2x 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. |
|
Controls compression acceleration feature. Choices:
|
|
Activates data reduction sharing functionality. Choices:
|
|
Quantity of volumes to create. Default: |
|
Storage pool identifier. |
|
Quality of service configuration for the volume. |
|
QoS alert configuration. |
|
Activates lower threshold alerts. Choices:
|
|
Activates response time alerts. Choices:
|
|
Activates upper threshold alerts. Choices:
|
|
Permitted duration for lower threshold alerts. |
|
Permitted duration for response time alerts. |
|
Permitted duration for upper threshold alerts. |
|
QoS threshold configuration. |
|
Activates minimum IOPS restriction. Choices:
|
|
Activates minimum transfer rate restriction. Choices:
|
|
Activates response priority setting. Choices:
|
|
Activates maximum IOPS restriction. Choices:
|
|
Activates maximum transfer rate restriction. Choices:
|
|
Minimum IOPS threshold. |
|
Minimum transfer rate threshold. |
|
Response priority level. |
|
Maximum IOPS threshold. |
|
Maximum transfer rate threshold. |
|
Data reduction function configuration. Choices:
|
|
Collection of server identifiers for volume attachment. |
|
Volume identifier. |
|
Naming configuration for the volume. |
|
Foundation name for volume naming. |
|
Digit count for the numerical portion of volume names. |
|
Initial number for volume name sequencing. |
|
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
saving_setting: "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 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 |
|
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 |
|
Saving setting (e.g., COMPRESSION). 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 |