ibm.spectrum_virtualize.ibm_svc_manage_replication 模块 – 此模块管理 IBM Spectrum Virtualize 系列存储系统上的远程复制(或 rcrelationship)
注意
此模块是 ibm.spectrum_virtualize 集合(版本 2.0.0)的一部分。
如果您正在使用 ansible 包,您可能已经安装了此集合。它不包含在 ansible-core 中。要检查它是否已安装,请运行 ansible-galaxy collection list。
要安装它,请使用:ansible-galaxy collection install ibm.spectrum_virtualize。
要在 playbook 中使用它,请指定:ibm.spectrum_virtualize.ibm_svc_manage_replication。
注意
ibm.spectrum_virtualize 集合已重命名为 ibm.storage_virtualize,并将从 Ansible 12 中删除。如果您使用 ibm.spectrum_virtualize 中的内容,请更新 playbook 和角色中的 FQCN!在创建新的 playbook 或角色时,请直接使用 ibm.storage_virtualize 中的内容。
ibm.spectrum_virtualize 1.3.0 中的新增功能
概要
- 用于管理远程复制的 Ansible 接口。 
参数
| 参数 | 注释 | 
|---|---|
| 指定创建远程复制时的辅助卷名称。 | |
| Spectrum Virtualize 存储系统的主机名或管理 IP。 | |
| 指定此关系将加入的一致性组。如果用户未指定,则将该关系创建为独立关系。 当 state=present 时适用。 | |
| 指定远程复制的镜像类型。“metro”表示 MetroMirror,“global”表示 GlobalMirror,“GMCV”表示带更改卷的 GlobalMirror。 如果未指定,则在创建远程复制时将创建 MetroMirror 远程复制 state=present。 选项 
 | |
| 以秒为单位指定循环周期。默认循环为 300 秒。 | |
| Spectrum Virtualize 存储系统的域。 当主机名用于参数 clustername 时有效。 | |
| 指定即使导致辅助卷包含不一致的数据,也必须删除该关系。 选项 
 | |
| 调试日志文件的路径。 | |
| 指定创建远程复制时的主卷名称。 | |
| 指定要分配给新的远程复制关系的名称,或操作现有远程复制关系的名称。 | |
| 指定是否从一致性组中删除指定的关系,使该关系成为独立关系。 当 state=present 时适用。 选项 
 | |
| Spectrum Virtualize 存储系统的 REST API 密码。 如果未使用 token 验证用户身份,则需要 username 和 password 参数。 | |
| 指定创建远程复制时的远程集群的名称。 | |
| 创建或更新( 选项 
 | |
| 指定是否创建同步关系。 选项 
 | |
| 用于验证 Spectrum Virtualize 存储系统上的用户的身份验证令牌。 要生成令牌,请使用 ibm_svc_auth 模块。 | |
| Spectrum Virtualize 存储系统的 REST API 用户名。 如果未使用 token 验证用户身份,则需要 username 和 password 参数。 | |
| 验证证书。 选项 
 | 
注释
注意
- 仅当远程复制关系不存在时,参数 primary 和 aux 才是必需的。 
- 此模块支持 - check_mode。
示例
- name: Create remote copy
  ibm.spectrum_virtualize.ibm_svc_manage_replication:
    name: sample_rcopy
    clustername: "{{clustername}}"
    username: "{{username}}"
    password: "{{password}}"
    log_path: /tmp/ansible.log
    state: present
    remotecluster: "{{remotecluster}}"
    master: SourceVolume0
    aux: TargetVolume0
    copytype: global
    sync: true
    consistgrp: sample_rccg
  register: result
- name: Exclude the remote copy from consistency group
  ibm.spectrum_virtualize.ibm_svc_manage_replication:
    name: sample_rcopy2
    clustername: "{{clustername}}"
    username: "{{username}}"
    password: "{{password}}"
    log_path: /tmp/ansible.log
    state: present
    noconsistgrp: true
- name: Delete remote copy
  ibm.spectrum_virtualize.ibm_svc_manage_replication:
    name: sample_rcopy3
    clustername: "{{clustername}}"
    username: "{{username}}"
    password: "{{password}}"
    log_path: /tmp/ansible.log
    state: absent
- name: Create GlobalMirror remote copy relationship with change volume
  ibm.spectrum_virtualize.ibm_svc_manage_replication:
    name: sample_rcopy4
    clustername: "{{clustername}}"
    username: "{{username}}"
    password: "{{password}}"
    log_path: /tmp/ansible.log
    state: present
    remotecluster: "{{remotecluster}}"
    master: SourceVolume1
    aux: TargetVolume1
    copytype: GMCV
    sync: true
  register: result
