ibm.storage_virtualize.ibm_sv_manage_clone module – This module manages clone and thinclone of volume and volumegroup
Note
This module is part of the ibm.storage_virtualize collection (version 3.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 ibm.storage_virtualize.
To use it in a playbook, specify: ibm.storage_virtualize.ibm_sv_manage_clone.
New in ibm.storage_virtualize 3.2.0
Synopsis
Ansible interface to manage ‘mkvolume’ and ‘mkvolumegroup’ clone commands.
Parameters
Parameter |
Comments |
|---|---|
The hostname, management IP or partition IP of the Storage Virtualize system. |
|
Domain for the Storage Virtualize system. Valid when hostname is used for the parameter clustername. |
|
Specifies colon-separated list of the parent volumes. The parameters fromsourcevolumes is mandatory for clone volumes and optional for clone volume groups while creating clone. |
|
Indicates that snapshots can be created with the scheduler or with the addsnapshot command, if any volumes in the volume group are used as a source volume in legacy FlashCopy mapping. Choices:
|
|
Specifies the name of the I/O group for the new clone. |
|
Path of debug log file. |
|
Specifies a name for the new clone. |
|
Specifies the name of the ownership group to which the object is being added. |
|
Specifies the name of the storage partition to be assigned to the volume group. |
|
REST API password for the Storage Virtualize system. The parameters username and password are required if not using token to authenticate a user. |
|
Specifies the name of the storage pool to use while creating the clone. The parameters pool is mandatory for clone volumes and optional for clone volume groups while creating clone. |
|
Specifies the preferred node that is used to access the volume. |
|
Specifies the name of the snapshot that is used to create the clone. The parameters fromsourcevolumes is mandatory for creating clone. |
|
Creates ( Choices:
|
|
The authentication token to verify a user on the Storage Virtualize system. To generate a token, use the ibm.storage_virtualize.ibm_svc_auth module. |
|
Specifies the type of clone to create. Volume can be thinclone or clone type. Choices:
|
|
REST API username for the Storage Virtualize system. The parameters username and password are required if not using token to authenticate a user. |
|
Validates certification. Choices:
|
|
Specifies the name of the volumegroup to which the clone is to be added. When logging in via partition IP, the volumegroup parameter is required to create a volume clone. |
Notes
Note
This module supports
check_mode.This module currently only supports the creation of clone volume or volumegroup (
state=present).Support for updating or removing these clone objects may be added in a future release. For updating (converting thinclone to clone) or removing thinclone or clone for volume and volumegroup, use the ibm_svc_manage_volume or ibm_svc_manage_volumegroup modules, respectively.
This module supports log-in via partition-ip.
Examples
- name: Create a clone of a volume from snapshot
ibm.storage_virtualize.ibm_svc_manage_clone:
clustername: "{{ clustername }}"
domain: "{{ domain }}"
username: "{{ username }}"
password: "{{ password }}"
log_path: "{{ log_path }}"
name: "vol1_clone_1"
state: "present"
pool: "pool1"
type: "clone"
snapshot: "snapshot1"
fromsourcevolumes: "vol1"
iogrp: "io_grp0"
preferrednode: "node1"
volumegroup: "Vg1"
- name: Create a clone of a volumegroup from snapshot
ibm.storage_virtualize.ibm_svc_manage_clone:
clustername: "{{ clustername }}"
domain: "{{ domain }}"
username: "{{ username }}"
password: "{{ password }}"
log_path: "{{ log_path }}"
name: "vg1_clone_1"
state: "present"
pool: "pool1"
type: "clone"
snapshot: "snapshot1"
iogrp: "io_grp0"
partition: "ptn1"
ownershipgroup: "grp1"
- name: Create a clone of volume vector from snapshot
ibm.storage_virtualize.ibm_svc_manage_clone:
clustername: "{{ clustername }}"
domain: "{{ domain }}"
username: "{{ username }}"
password: "{{ password }}"
log_path: "{{ log_path }}"
name: "vg1_clone_1"
state: "present"
fromsourcevolumes: "vol1:vol2:vol3"
pool: "pool1"
type: "clone"
snapshot: "snapshot1"
iogrp: "io_grp0"
partition: "ptn1"
ownershipgroup: "grp1"