hitachivantara.vspone_block.vsp.hv_vsp_one_server module – Manages servers 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_server.
New in hitachivantara.vspone_block 4.3.0
Synopsis
This module enables register, modification, and deletion of servers, as well as various server operations.
Supports various server operations depending on the specified state parameter.
Utilizes the Hitachi Virtual Storage Platform One Simple API for server management across VSP E series, VSP One B20 series, and VSP One B80 series models.
For usage examples, visit https://github.com/hitachi-vantara/vspone-block-ansible/blob/main/playbooks/vsp_direct/vsp_one_server.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 server operation. |
|
List of HBA configurations. Required for the Register a FC server with HBA WWN /Register an iSCSI server with iSCSI names /Register server with multiple HBAs and paths configuration /Register iSCSI server with multiple HBAs and paths /Register reserved server with specific configuration /Add HBA to existing FC server /Add iSCSI HBA to existing iSCSI server /Remove HBA from FC server /Remove iSCSI HBA from iSCSI server /Register HP-UX server with comprehensive configuration tasks. |
|
HBA WWN address. Required for the Register a FC server with HBA WWN /Register server with multiple HBAs and paths configuration /Register reserved server with specific configuration /Add HBA to existing FC server /Remove HBA from FC server /Register HP-UX server with comprehensive configuration tasks. |
|
iSCSI name. Required for the Register an iSCSI server with iSCSI names /Register iSCSI server with multiple HBAs and paths /Add iSCSI HBA to existing iSCSI server /Remove iSCSI HBA from iSCSI server tasks. |
|
List of host group configurations. Required for the Register server with host groups configuration /Add host groups to existing server /Register HP-UX server with comprehensive configuration tasks. |
|
Host group identifier. |
|
Host group name. Required for the Register server with host groups configuration /Add host groups to existing server /Register HP-UX server with comprehensive configuration tasks. |
|
Port identifier. Required for the Register server with host groups configuration /Add host groups to existing server /Register HP-UX server with comprehensive configuration tasks. |
|
Indicates if the server is reserved. Required for the Register a basic server with minimal configuration /Register reserved server with specific configuration tasks. Choices:
|
|
List of iSCSI target configurations. Required for the Change the iSCSI target settings for existing server tasks. |
|
Port identifier. Required for the Change the iSCSI target settings for existing server task. |
|
iSCSI target name. Required for the Change the iSCSI target settings for existing server task. |
|
List of iSCSI target configurations. |
|
iSCSI target identifier. |
|
iSCSI target name. |
|
Port identifier. |
|
Whether to keep LUN configuration. Required for the Register HP-UX server with comprehensive configuration /Delete server by server_id and keep lun configuration tasks. Choices:
|
|
Server nickname specification. Required for the Register a basic server with minimal configuration /Register a FC server with HBA WWN /Register an iSCSI server with iSCSI names /Register server with host groups configuration /Register server with multiple HBAs and paths configuration /Register iSCSI server with multiple HBAs and paths /Register reserved server with specific configuration /Update existing server nick_name (using server_id) /Register HP-UX server with comprehensive configuration /Delete server using nick_name tasks. |
|
Operating system type of the server. Required for the Register a basic server with minimal configuration /Register a FC server with HBA WWN /Register an iSCSI server with iSCSI names /Register server with host groups configuration /Register server with multiple HBAs and paths configuration /Register iSCSI server with multiple HBAs and paths /Register reserved server with specific configuration /Update existing server settings like os type options using server_id /Register HP-UX server with comprehensive configuration tasks. Choices:
|
|
List of OS type option identifiers. Required for the Register reserved server with specific configuration /Update existing server settings like os type options using server_id tasks. |
|
List of path configurations. Required for the Register server with multiple HBAs and paths configuration /Register iSCSI server with multiple HBAs and paths /Add path to server /Remove path from server /Register HP-UX server with comprehensive configuration tasks. |
|
HBA WWN address. Required for the Register server with multiple HBAs and paths configuration /Add path to server /Remove path from server /Register HP-UX server with comprehensive configuration tasks. |
|
iSCSI name. Required for the Register iSCSI server with multiple HBAs and paths tasks |
|
List of port identifiers. Required for the Register server with multiple HBAs and paths configuration /Register iSCSI server with multiple HBAs and paths /Add path to server /Remove path from server /Register HP-UX server with comprehensive configuration tasks. |
|
List of port identifiers. |
|
Server protocol type. Required for the Register a basic server with minimal configuration /Register a FC server with HBA WWN /Register an iSCSI server with iSCSI names /Register server with host groups configuration /Register server with multiple HBAs and paths configuration /Register iSCSI server with multiple HBAs and paths /Register reserved server with specific configuration /Register HP-UX server with comprehensive configuration tasks. Choices:
|
|
Server identifier. Required for the Update existing server nick_name (using server_id) /Update existing server settings like os type options using server_id /Add host groups to existing server /Add HBA to existing FC server /Add iSCSI HBA to existing iSCSI server /Remove HBA from FC server /Remove iSCSI HBA from iSCSI server /Add path to server /Remove path from server /Sync server nickname /Change the iSCSI target settings for existing server /Delete server by server_id and keep lun configuration tasks. |
|
Defines the server operation type. Available options include Choices:
|
Attributes
Attribute |
Support |
Description |
|---|---|---|
Support: none |
Specifies whether the module operates in check mode. |
Examples
- name: Register a FC server with HBA WWN
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
nick_name: "WebServer01"
protocol: "FC"
os_type: "Linux"
hbas:
- hba_wwn: "50060e8010203040"
- name: Register an iSCSI server with iSCSI name
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
nick_name: "DatabaseServer01"
protocol: "iSCSI"
os_type: "Windows"
hbas:
- iscsi_name: "iqn.1991-05.com.microsoft:server01"
- name: Register server with host groups configuration
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
nick_name: "VMwareCluster01"
protocol: "FC"
os_type: "VMware"
host_groups:
- host_group_name: "VMware_HG01"
port_id: "CL1-A"
- host_group_name: "VMware_HG02"
port_id: "CL1-B"
- name: Register server with multiple HBAs and paths configuration
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
nick_name: "AppServer01"
protocol: "FC"
os_type: "Linux"
hbas:
- hba_wwn: "50060e8010203040"
- hba_wwn: "50060e8010203041"
paths:
- port_ids: ["CL1-A", "CL1-B"]
hba_wwn: "50060e8010203040"
- port_ids: ["CL2-A", "CL2-B"]
hba_wwn: "50060e8010203041"
- name: Register iSCSI server with multiple iSCSI names and paths
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
nick_name: "HybridServer01"
protocol: "iSCSI"
os_type: "Linux"
hbas:
- iscsi_name: "iqn.1991-05.com.example:server01-iscsi1"
- iscsi_name: "iqn.1991-05.com.example:server01-iscsi2"
paths:
- port_ids: ["CL1-A"]
iscsi_name: "iqn.1991-05.com.example:server01-iscsi1"
- port_ids: ["CL1-B"]
iscsi_name: "iqn.1991-05.com.example:server01-iscsi2"
- name: Update existing server nick_name with server_id
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 123
nick_name: "UpdatedServerName"
- name: Update existing server settings like os type os type options using server_id
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 123
os_type: "Windows"
os_type_options: [1, 2]
- name: Add host groups to existing server
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: add_host_groups
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 123
host_groups:
- host_group_name: "NewHostGroup01"
port_id: "CL2-A"
- name: Add HBA to existing server using server_id
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: add_hba
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 123
hbas:
- hba_wwn: "50060e8010203042"
- name: Remove HBA from server
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: remove_hba
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 12
hbas:
- hba_wwn: "50060e8010203042"
- name: Add path to server
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: add_path
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 12
paths:
- port_ids: ["CL1-C", "CL1-D"]
hba_wwn: "50060e8010203040"
- name: Remove path from server
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: remove_path
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 12
paths:
- port_ids: ["CL1-C"]
hba_wwn: "50060e8010203040"
- name: Sync server nickname with host group
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: sync_server_nick_name
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 123
- name: Register reserved server with specific configuration
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
nick_name: "ReservedServer01"
protocol: "FC"
os_type: "Solaris"
is_reserved: true
keep_lun_config: true
os_type_options: [1, 2]
- name: Change the iSCSI target settings for existing server (change target name)
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: present
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 123
iscsi_targets:
- port_id: "CL1-A"
iscsi_target_name: "iqn.1992-04.com.hitachi:target01"
- port_id: "CL1-B"
iscsi_target_name: "iqn.1992-04.com.hitachi:target02"
- name: Delete server using server_id and keep lun configuration
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: absent
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
server_id: 123
keep_lun_config: true
- name: Delete server using nick_name.
hitachivantara.vspone_block.vsp.hv_vsp_one_server:
state: absent
connection_info:
address: vsp.company.com
username: "admin"
password: "password"
spec:
nick_name: "WebServer01"
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
|---|---|
Server information returned after operation Returned: always |
|
Server compatibility status Returned: always Sample: |
|
Indicates if server has non-fullmesh LU paths Returned: always Sample: |
|
Indicates if server has unaligned OS type options Returned: always Sample: |
|
Indicates if server has unaligned OS types Returned: always Sample: |
|
Server identifier Returned: always Sample: |
|
Indicates if server configuration is inconsistent Returned: always Sample: |
|
Indicates if server is reserved Returned: always Sample: |
|
Indicates if server modification is in progress Returned: always Sample: |
|
Server nickname Returned: always Sample: |
|
Number of paths configured for the server Returned: always Sample: |
|
Number of volumes attached to the server Returned: always Sample: |
|
Operating system type of the server Returned: always Sample: |
|
List of OS type option identifiers Returned: always Sample: |
|
List of server path configurations Returned: always |
|
HBA WWN address Returned: always Sample: |
|
iSCSI name Returned: always Sample: |
|
List of port identifiers Returned: always Sample: |
|
Server protocol type Returned: always Sample: |
|
Total capacity in GB Returned: always Sample: |
|
Used capacity in GB Returned: always Sample: |