hitachivantara.vspone_block.sds_block.hv_sds_block_volume module – Manages Hitachi SDS block storage system volumes.

Note

This module is part of the hitachivantara.vspone_block collection (version 3.4.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.sds_block.hv_sds_block_volume.

New in hitachivantara.vspone_block 3.0.0

Synopsis

Requirements

The below requirements are needed on the host that executes this module.

  • python >= 3.8

Parameters

Parameter

Comments

connection_info

dictionary / required

Information required to establish a connection to the storage system.

address

string / required

IP address or hostname of the storage system.

connection_type

string

Type of connection to the storage system.

Choices:

  • "direct" ← (default)

password

string / required

Password for authentication.

username

string / required

Username for authentication.

spec

dictionary / required

Specification for the volume task.

capacity

string

The capacity of the volume.

capacity_saving

string

Settings of the data reduction function. Disabled or Compression.

compute_nodes

list / elements=string

The array of name of compute nodes to which the volume is attached.

id

string

The id of the volume.

name

string

The name of the volume.

nickname

string

The nickname of the volume.

pool_name

string

The name of the storage pool where the volume is created.

qos_param

dictionary

The quality of service parameters for the volume.

upper_alert_allowable_time_in_sec

integer

The upper alert allowable time(In seconds).

upper_limit_for_iops

integer

The upper limit for IOPS.

upper_limit_for_transfer_rate_mb_per_sec

integer

The upper limit for transfer rate (MB per Sec).

state

string

The state of the volume task.

Choices:

  • "add_compute_node"

  • "remove_compute_node"

state

string

The level of the volume task. Choices are present and absent.

Choices:

  • "present" ← (default)

  • "absent"

Attributes

Attribute

Support

Description

check_mode

Support: none

Determines if the module should run in check mode.

Examples

- name: Create volume
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: present
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      pool_name: "SP01"
      name: "RD-volume-4"
      capacity: 99
      compute_nodes: ["CAPI123678", "ComputeNode-1"]

- name: Create volume with QoS parameters
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: present
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      pool_name: "SP01"
      name: "RD-volume-4"
      capacity: 99
      qos_param:
        upper_limit_for_iops: 100
        upper_limit_for_transfer_rate_mb_per_sec: 100
        upper_alert_allowable_time_in_sec: 100
      compute_nodes: ["CAPI123678", "ComputeNode-1"]

- name: Delete volume by ID
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: absent
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      id: "df63a5d9-32ea-4ae1-879a-7c23fbc574db"

- name: Delete volume by name
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: absent
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      name: "RD-volume-4"

- name: Expand volume
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: present
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      name: "RD-volume-4"
      capacity: 202

- name: Update volume nickname
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: present
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      name: "RD-volume-4"
      nickname: "RD-volume-0004"

- name: Update volume QoS parameters
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: present
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      name: "RD-volume-4"
      qos_param:
        upper_limit_for_iops: 100
        upper_limit_for_transfer_rate_mb_per_sec: 100
        upper_alert_allowable_time_in_sec: 100

- name: Update volume name
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: present
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      id: "aba5c900-b04c-4beb-8ca4-ed53537afb09"
      name: "RD-volume-0004"
      nickname: "RD-volume-0004"

- name: Remove compute node
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: present
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      state: "remove_compute_node"
      id: "aba5c900-b04c-4beb-8ca4-ed53537afb09"
      compute_nodes: ["ComputeNode-1"]

- name: Add compute node
  hitachivantara.vspone_block.sds_block.hv_sds_block_volume:
    state: present
    connection_info:
      address: sdsb.company.com
      username: "admin"
      password: "password"
    spec:
      state: "add_compute_node"
      id: "aba5c900-b04c-4beb-8ca4-ed53537afb09"
      compute_nodes: ["ComputeNode-1"]

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

data

dictionary

The volume information.

Returned: always

compute_node_info

list / elements=dictionary

List of compute nodes to which the volume is attached.

Returned: success

id

string

Unique identifier for the compute node.

Returned: success

Sample: "4f9041aa-ab2f-4789-af2e-df4a0178a4d3"

name

string

Name of the compute node.

Returned: success

Sample: "asishtest"

volume_info

dictionary

Detailed information about the volume.

Returned: success

capacity_saving

string

Capacity saving status.

Returned: success

Sample: "Disabled"

data_reduction_effects

dictionary

Data reduction effects on the volume.

Returned: success

post_capacity_data_reduction

integer

Post capacity data reduction.

Returned: success

Sample: 0

pre_capacity_data_reduction_without_system_data

integer

Pre capacity data reduction without system data.

Returned: success

Sample: 0

system_data_capacity

integer

System data capacity.

Returned: success

Sample: 0

data_reduction_progress_rate

boolean

Data reduction progress rate.

Returned: success

Sample: false

data_reduction_status

string

Data reduction status.

Returned: success

Sample: "Disabled"

full_allocated

boolean

Whether the volume is fully allocated.

Returned: success

Sample: false

id

string

Unique identifier for the volume.

Returned: success

Sample: "ef69d5c6-ed7c-4302-959f-b8b8a7382f3b"

naa_id

string

NAA identifier for the volume.

Returned: success

Sample: "60060e810a85a000600a85a000000017"

name

string

Name of the volume.

Returned: success

Sample: "vol010"

nickname

string

Nickname of the volume.

Returned: success

Sample: "vol010"

number_of_connecting_servers

integer

Number of servers connected to the volume.

Returned: success

Sample: 1

number_of_snapshots

integer

Number of snapshots of the volume.

Returned: success

Sample: 0

pool_id

string

Pool identifier where the volume is created.

Returned: success

Sample: "cb9f7ecf-ceba-4d8e-808b-9c7bc3e59c03"

pool_name

string

Name of the storage pool.

Returned: success

Sample: "SP01"

protection_domain_id

string

Protection domain identifier.

Returned: success

Sample: "645c36b6-da9e-44bb-b711-430e06c7ad2b"

qos_param

dictionary

Quality of service parameters for the volume.

Returned: success

upper_alert_allowable_time

integer

Upper alert allowable time.

Returned: success

Sample: -1

upper_alert_time

boolean

Upper alert time.

Returned: success

Sample: false

upper_limit_for_iops

integer

Upper limit for IOPS.

Returned: success

Sample: -1

upper_limit_for_transfer_rate

integer

Upper limit for transfer rate.

Returned: success

Sample: -1

saving_mode

boolean

Whether the saving mode is enabled.

Returned: success

Sample: false

snapshot_attribute

string

Snapshot attribute.

Returned: success

Sample: "-"

snapshot_status

boolean

Snapshot status.

Returned: success

Sample: false

status

string

Status of the volume.

Returned: success

Sample: "Normal"

status_summary

string

Summary of the volume status.

Returned: success

Sample: "Normal"

storage_controller_id

string

Storage controller identifier.

Returned: success

Sample: "fc22f6d3-2bd3-4df5-b5db-8a728e301af9"

total_capacity_mb

integer

Total capacity of the volume in MB.

Returned: success

Sample: 120

used_capacity_mb

integer

Used capacity of the volume in MB.

Returned: success

Sample: 0

volume_number

integer

Volume number.

Returned: success

Sample: 23

volume_type

string

Type of the volume.

Returned: success

Sample: "Normal"

vps_id

string

VPS identifier.

Returned: success

Sample: "(system)"

vps_name

string

VPS name.

Returned: success

Sample: "(system)"

Authors

  • Hitachi Vantara LTD (@hitachi-vantara)