| 1 |
.. _replication_consistency_group_module: |
| 2 |
|
| 3 |
|
| 4 |
replication_consistency_group -- Manage replication consistency groups on Dell PowerFlex |
| 5 |
======================================================================================== |
| 6 |
|
| 7 |
.. contents:: |
| 8 |
:local: |
| 9 |
:depth: 1 |
| 10 |
|
| 11 |
|
| 12 |
Synopsis |
| 13 |
-------- |
| 14 |
|
| 15 |
Managing replication consistency groups on PowerFlex storage system includes getting details, creating, modifying, creating snapshots, pause, resume, freeze, unfreeze, activate, failover, reverse, restore, sync, switchover, inactivate and deleting a replication consistency group. |
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
Requirements |
| 20 |
------------ |
| 21 |
The below requirements are needed on the host that executes this module. |
| 22 |
|
| 23 |
- A Dell PowerFlex storage system version 3.6 or later. |
| 24 |
- PyPowerFlex 2.0.0. |
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
Parameters |
| 29 |
---------- |
| 30 |
|
| 31 |
rcg_name (optional, str, None) |
| 32 |
The name of the replication consistency group. |
| 33 |
|
| 34 |
It is unique across the PowerFlex array. |
| 35 |
|
| 36 |
Mutually exclusive with :emphasis:`rcg\_id`. |
| 37 |
|
| 38 |
|
| 39 |
rcg_id (optional, str, None) |
| 40 |
The ID of the replication consistency group. |
| 41 |
|
| 42 |
Mutually exclusive with :emphasis:`rcg\_name`. |
| 43 |
|
| 44 |
|
| 45 |
create_snapshot (optional, bool, None) |
| 46 |
Whether to create the snapshot of the replication consistency group. |
| 47 |
|
| 48 |
|
| 49 |
rpo (optional, int, None) |
| 50 |
Desired RPO in seconds. |
| 51 |
|
| 52 |
|
| 53 |
protection_domain_id (optional, str, None) |
| 54 |
Protection domain id. |
| 55 |
|
| 56 |
Mutually exclusive with :emphasis:`protection\_domain\_name`. |
| 57 |
|
| 58 |
|
| 59 |
protection_domain_name (optional, str, None) |
| 60 |
Protection domain name. |
| 61 |
|
| 62 |
Mutually exclusive with :emphasis:`protection\_domain\_id`. |
| 63 |
|
| 64 |
|
| 65 |
activity_mode (optional, str, None) |
| 66 |
Activity mode of RCG. |
| 67 |
|
| 68 |
This parameter is supported for version 3.6 and above. |
| 69 |
|
| 70 |
|
| 71 |
rcg_state (optional, str, None) |
| 72 |
Specify an action for RCG. |
| 73 |
|
| 74 |
Failover the RCG. |
| 75 |
|
| 76 |
Reverse the RCG. |
| 77 |
|
| 78 |
Restore the RCG. |
| 79 |
|
| 80 |
Switchover the RCG. |
| 81 |
|
| 82 |
Pause or resume the RCG. |
| 83 |
|
| 84 |
Freeze or unfreeze the RCG. |
| 85 |
|
| 86 |
Synchronize the RCG. |
| 87 |
|
| 88 |
|
| 89 |
force (optional, bool, None) |
| 90 |
Force switchover the RCG. |
| 91 |
|
| 92 |
|
| 93 |
pause_mode (optional, str, None) |
| 94 |
Pause mode. |
| 95 |
|
| 96 |
It is required if pause is set as true. |
| 97 |
|
| 98 |
|
| 99 |
target_volume_access_mode (optional, str, None) |
| 100 |
Target volume access mode. |
| 101 |
|
| 102 |
|
| 103 |
is_consistent (optional, bool, None) |
| 104 |
Consistency of RCG. |
| 105 |
|
| 106 |
|
| 107 |
new_rcg_name (optional, str, None) |
| 108 |
Name of RCG to rename to. |
| 109 |
|
| 110 |
|
| 111 |
remote_peer (optional, dict, None) |
| 112 |
Remote peer system. |
| 113 |
|
| 114 |
|
| 115 |
hostname (True, str, None) |
| 116 |
IP or FQDN of the remote peer gateway host. |
| 117 |
|
| 118 |
|
| 119 |
username (True, str, None) |
| 120 |
The username of the remote peer gateway host. |
| 121 |
|
| 122 |
|
| 123 |
password (True, str, None) |
| 124 |
The password of the remote peer gateway host. |
| 125 |
|
| 126 |
|
| 127 |
validate_certs (optional, bool, True) |
| 128 |
Boolean variable to specify whether or not to validate SSL certificate. |
| 129 |
|
| 130 |
:literal:`true` - Indicates that the SSL certificate should be verified. |
| 131 |
|
| 132 |
:literal:`false` - Indicates that the SSL certificate should not be verified. |
| 133 |
|
| 134 |
|
| 135 |
port (optional, int, 443) |
| 136 |
Port number through which communication happens with remote peer gateway host. |
| 137 |
|
| 138 |
|
| 139 |
timeout (optional, int, 120) |
| 140 |
Time after which connection will get terminated. |
| 141 |
|
| 142 |
It is to be mentioned in seconds. |
| 143 |
|
| 144 |
|
| 145 |
protection_domain_id (optional, str, None) |
| 146 |
Remote protection domain id. |
| 147 |
|
| 148 |
Mutually exclusive with :emphasis:`protection\_domain\_name`. |
| 149 |
|
| 150 |
|
| 151 |
protection_domain_name (optional, str, None) |
| 152 |
Remote protection domain name. |
| 153 |
|
| 154 |
Mutually exclusive with :emphasis:`protection\_domain\_id`. |
| 155 |
|
| 156 |
|
| 157 |
|
| 158 |
state (optional, str, present) |
| 159 |
State of the replication consistency group. |
| 160 |
|
| 161 |
|
| 162 |
hostname (True, str, None) |
| 163 |
IP or FQDN of the PowerFlex host. |
| 164 |
|
| 165 |
|
| 166 |
username (True, str, None) |
| 167 |
The username of the PowerFlex host. |
| 168 |
|
| 169 |
|
| 170 |
password (True, str, None) |
| 171 |
The password of the PowerFlex host. |
| 172 |
|
| 173 |
|
| 174 |
validate_certs (optional, bool, True) |
| 175 |
Boolean variable to specify whether or not to validate SSL certificate. |
| 176 |
|
| 177 |
:literal:`true` - Indicates that the SSL certificate should be verified. |
| 178 |
|
| 179 |
:literal:`false` - Indicates that the SSL certificate should not be verified. |
| 180 |
|
| 181 |
|
| 182 |
port (optional, int, 443) |
| 183 |
Port number through which communication happens with PowerFlex host. |
| 184 |
|
| 185 |
|
| 186 |
timeout (False, int, 120) |
| 187 |
Time after which connection will get terminated. |
| 188 |
|
| 189 |
It is to be mentioned in seconds. |
| 190 |
|
| 191 |
|
| 192 |
|
| 193 |
|
| 194 |
|
| 195 |
Notes |
| 196 |
----- |
| 197 |
|
| 198 |
.. note:: |
| 199 |
- The :emphasis:`check\_mode` is supported. |
| 200 |
- Idempotency is not supported for create snapshot operation. |
| 201 |
- There is a delay in reflection of final state of RCG after few update operations on RCG. |
| 202 |
- In 3.6 and above, the replication consistency group will return back to consistent mode on changing to inconsistent mode if consistence barrier arrives. Hence idempotency on setting to inconsistent mode will return changed as true. |
| 203 |
- The pause and freeze parameters are removed in 3.0.0 version. Use 'rcg\_state' param instead. |
| 204 |
- The modules present in the collection named as 'dellemc.powerflex' are built to support the Dell PowerFlex storage platform. |
| 205 |
|
| 206 |
|
| 207 |
|
| 208 |
|
| 209 |
Examples |
| 210 |
-------- |
| 211 |
|
| 212 |
.. code-block:: yaml+jinja |
| 213 |
|
| 214 |
|
| 215 |
|
| 216 |
- name: Get RCG details |
| 217 |
dellemc.powerflex.replication_consistency_group: |
| 218 |
hostname: "{{hostname}}" |
| 219 |
username: "{{username}}" |
| 220 |
password: "{{password}}" |
| 221 |
validate_certs: "{{validate_certs}}" |
| 222 |
port: "{{port}}" |
| 223 |
rcg_name: "{{rcg_name}}" |
| 224 |
|
| 225 |
- name: Create a snapshot of the RCG |
| 226 |
dellemc.powerflex.replication_consistency_group: |
| 227 |
hostname: "{{hostname}}" |
| 228 |
username: "{{username}}" |
| 229 |
password: "{{password}}" |
| 230 |
validate_certs: "{{validate_certs}}" |
| 231 |
port: "{{port}}" |
| 232 |
rcg_id: "{{rcg_id}}" |
| 233 |
create_snapshot: true |
| 234 |
state: "present" |
| 235 |
|
| 236 |
- name: Create a replication consistency group |
| 237 |
dellemc.powerflex.replication_consistency_group: |
| 238 |
hostname: "{{hostname}}" |
| 239 |
username: "{{username}}" |
| 240 |
password: "{{password}}" |
| 241 |
validate_certs: "{{validate_certs}}" |
| 242 |
port: "{{port}}" |
| 243 |
rcg_name: "rcg_test" |
| 244 |
rpo: 60 |
| 245 |
protection_domain_name: "domain1" |
| 246 |
activity_mode: "active" |
| 247 |
remote_peer: |
| 248 |
hostname: "{{hostname}}" |
| 249 |
username: "{{username}}" |
| 250 |
password: "{{password}}" |
| 251 |
validate_certs: "{{validate_certs}}" |
| 252 |
port: "{{port}}" |
| 253 |
protection_domain_name: "domain1" |
| 254 |
|
| 255 |
- name: Modify replication consistency group |
| 256 |
dellemc.powerflex.replication_consistency_group: |
| 257 |
hostname: "{{hostname}}" |
| 258 |
username: "{{username}}" |
| 259 |
password: "{{password}}" |
| 260 |
validate_certs: "{{validate_certs}}" |
| 261 |
port: "{{port}}" |
| 262 |
rcg_name: "rcg_test" |
| 263 |
rpo: 60 |
| 264 |
target_volume_access_mode: "ReadOnly" |
| 265 |
activity_mode: "Inactive" |
| 266 |
is_consistent: true |
| 267 |
|
| 268 |
- name: Rename replication consistency group |
| 269 |
dellemc.powerflex.replication_consistency_group: |
| 270 |
hostname: "{{hostname}}" |
| 271 |
username: "{{username}}" |
| 272 |
password: "{{password}}" |
| 273 |
validate_certs: "{{validate_certs}}" |
| 274 |
port: "{{port}}" |
| 275 |
rcg_name: "rcg_test" |
| 276 |
new_rcg_name: "rcg_test_rename" |
| 277 |
|
| 278 |
- name: Pause replication consistency group |
| 279 |
dellemc.powerflex.replication_consistency_group: |
| 280 |
hostname: "{{hostname}}" |
| 281 |
username: "{{username}}" |
| 282 |
password: "{{password}}" |
| 283 |
validate_certs: "{{validate_certs}}" |
| 284 |
port: "{{port}}" |
| 285 |
rcg_name: "rcg_test" |
| 286 |
rcg_state: "pause" |
| 287 |
pause_mode: "StopDataTransfer" |
| 288 |
|
| 289 |
- name: Resume replication consistency group |
| 290 |
dellemc.powerflex.replication_consistency_group: |
| 291 |
hostname: "{{hostname}}" |
| 292 |
username: "{{username}}" |
| 293 |
password: "{{password}}" |
| 294 |
validate_certs: "{{validate_certs}}" |
| 295 |
port: "{{port}}" |
| 296 |
rcg_name: "rcg_test" |
| 297 |
rcg_state: "resume" |
| 298 |
|
| 299 |
- name: Freeze replication consistency group |
| 300 |
dellemc.powerflex.replication_consistency_group: |
| 301 |
hostname: "{{hostname}}" |
| 302 |
username: "{{username}}" |
| 303 |
password: "{{password}}" |
| 304 |
validate_certs: "{{validate_certs}}" |
| 305 |
port: "{{port}}" |
| 306 |
rcg_name: "rcg_test" |
| 307 |
rcg_state: "freeze" |
| 308 |
|
| 309 |
- name: UnFreeze replication consistency group |
| 310 |
dellemc.powerflex.replication_consistency_group: |
| 311 |
hostname: "{{hostname}}" |
| 312 |
username: "{{username}}" |
| 313 |
password: "{{password}}" |
| 314 |
validate_certs: "{{validate_certs}}" |
| 315 |
port: "{{port}}" |
| 316 |
rcg_name: "rcg_test" |
| 317 |
rcg_state: "unfreeze" |
| 318 |
|
| 319 |
- name: Failover replication consistency group |
| 320 |
dellemc.powerflex.replication_consistency_group: |
| 321 |
hostname: "{{hostname}}" |
| 322 |
username: "{{username}}" |
| 323 |
password: "{{password}}" |
| 324 |
validate_certs: "{{validate_certs}}" |
| 325 |
port: "{{port}}" |
| 326 |
rcg_name: "rcg_test" |
| 327 |
rcg_state: "failover" |
| 328 |
|
| 329 |
- name: Reverse replication consistency group |
| 330 |
dellemc.powerflex.replication_consistency_group: |
| 331 |
hostname: "{{hostname}}" |
| 332 |
username: "{{username}}" |
| 333 |
password: "{{password}}" |
| 334 |
validate_certs: "{{validate_certs}}" |
| 335 |
port: "{{port}}" |
| 336 |
rcg_name: "rcg_test" |
| 337 |
rcg_state: "reverse" |
| 338 |
|
| 339 |
- name: Restore replication consistency group |
| 340 |
dellemc.powerflex.replication_consistency_group: |
| 341 |
hostname: "{{hostname}}" |
| 342 |
username: "{{username}}" |
| 343 |
password: "{{password}}" |
| 344 |
validate_certs: "{{validate_certs}}" |
| 345 |
port: "{{port}}" |
| 346 |
rcg_name: "rcg_test" |
| 347 |
rcg_state: "restore" |
| 348 |
|
| 349 |
- name: Switchover replication consistency group |
| 350 |
dellemc.powerflex.replication_consistency_group: |
| 351 |
hostname: "{{hostname}}" |
| 352 |
username: "{{username}}" |
| 353 |
password: "{{password}}" |
| 354 |
validate_certs: "{{validate_certs}}" |
| 355 |
port: "{{port}}" |
| 356 |
rcg_name: "rcg_test" |
| 357 |
rcg_state: "switchover" |
| 358 |
|
| 359 |
- name: Synchronize replication consistency group |
| 360 |
dellemc.powerflex.replication_consistency_group: |
| 361 |
hostname: "{{hostname}}" |
| 362 |
username: "{{username}}" |
| 363 |
password: "{{password}}" |
| 364 |
validate_certs: "{{validate_certs}}" |
| 365 |
port: "{{port}}" |
| 366 |
rcg_name: "rcg_test" |
| 367 |
rcg_state: "sync" |
| 368 |
|
| 369 |
- name: Delete replication consistency group |
| 370 |
dellemc.powerflex.replication_consistency_group: |
| 371 |
hostname: "{{hostname}}" |
| 372 |
username: "{{username}}" |
| 373 |
password: "{{password}}" |
| 374 |
validate_certs: "{{validate_certs}}" |
| 375 |
port: "{{port}}" |
| 376 |
rcg_name: "rcg_test" |
| 377 |
state: "absent" |
| 378 |
|
| 379 |
|
| 380 |
|
| 381 |
Return Values |
| 382 |
------------- |
| 383 |
|
| 384 |
changed (always, bool, false) |
| 385 |
Whether or not the resource has changed. |
| 386 |
|
| 387 |
|
| 388 |
replication_consistency_group_details (When replication consistency group exists, dict, {'protectionDomainId': 'b969400500000000', 'peerMdmId': '6c3d94f600000000', 'remoteId': '2130961a00000000', 'remoteMdmId': '0e7a082862fedf0f', 'currConsistMode': 'Consistent', 'freezeState': 'Unfrozen', 'lifetimeState': 'Normal', 'pauseMode': 'None', 'snapCreationInProgress': False, 'lastSnapGroupId': 'e58280b300000001', 'lastSnapCreationRc': 'SUCCESS', 'targetVolumeAccessMode': 'NoAccess', 'remoteProtectionDomainId': '4eeb304600000000', 'remoteProtectionDomainName': 'domain1', 'failoverType': 'None', 'failoverState': 'None', 'activeLocal': True, 'activeRemote': True, 'abstractState': 'Ok', 'localActivityState': 'Active', 'remoteActivityState': 'Active', 'inactiveReason': 11, 'rpoInSeconds': 30, 'replicationDirection': 'LocalToRemote', 'disasterRecoveryState': 'None', 'remoteDisasterRecoveryState': 'None', 'error': 65, 'name': 'test_rcg', 'type': 'User', 'id': 'aadc17d500000000'}) |
| 389 |
Details of the replication consistency group. |
| 390 |
|
| 391 |
|
| 392 |
id (, str, ) |
| 393 |
The ID of the replication consistency group. |
| 394 |
|
| 395 |
|
| 396 |
name (, str, ) |
| 397 |
The name of the replication consistency group. |
| 398 |
|
| 399 |
|
| 400 |
protectionDomainId (, str, ) |
| 401 |
The Protection Domain ID of the replication consistency group. |
| 402 |
|
| 403 |
|
| 404 |
peerMdmId (, str, ) |
| 405 |
The ID of the peer MDM of the replication consistency group. |
| 406 |
|
| 407 |
|
| 408 |
remoteId (, str, ) |
| 409 |
The ID of the remote replication consistency group. |
| 410 |
|
| 411 |
|
| 412 |
remoteMdmId (, str, ) |
| 413 |
The ID of the remote MDM of the replication consistency group. |
| 414 |
|
| 415 |
|
| 416 |
currConsistMode (, str, ) |
| 417 |
The current consistency mode of the replication consistency group. |
| 418 |
|
| 419 |
|
| 420 |
freezeState (, str, ) |
| 421 |
The freeze state of the replication consistency group. |
| 422 |
|
| 423 |
|
| 424 |
lifetimeState (, str, ) |
| 425 |
The Lifetime state of the replication consistency group. |
| 426 |
|
| 427 |
|
| 428 |
pauseMode (, str, ) |
| 429 |
The Lifetime state of the replication consistency group. |
| 430 |
|
| 431 |
|
| 432 |
snapCreationInProgress (, bool, ) |
| 433 |
Whether the process of snapshot creation of the replication consistency group is in progress or not. |
| 434 |
|
| 435 |
|
| 436 |
lastSnapGroupId (, str, ) |
| 437 |
ID of the last snapshot of the replication consistency group. |
| 438 |
|
| 439 |
|
| 440 |
lastSnapCreationRc (, int, ) |
| 441 |
The return code of the last snapshot of the replication consistency group. |
| 442 |
|
| 443 |
|
| 444 |
targetVolumeAccessMode (, str, ) |
| 445 |
The access mode of the target volume of the replication consistency group. |
| 446 |
|
| 447 |
|
| 448 |
remoteProtectionDomainId (, str, ) |
| 449 |
The ID of the remote Protection Domain. |
| 450 |
|
| 451 |
|
| 452 |
remoteProtectionDomainName (, str, ) |
| 453 |
The Name of the remote Protection Domain. |
| 454 |
|
| 455 |
|
| 456 |
failoverType (, str, ) |
| 457 |
The type of failover of the replication consistency group. |
| 458 |
|
| 459 |
|
| 460 |
failoverState (, str, ) |
| 461 |
The state of failover of the replication consistency group. |
| 462 |
|
| 463 |
|
| 464 |
activeLocal (, bool, ) |
| 465 |
Whether the local replication consistency group is active. |
| 466 |
|
| 467 |
|
| 468 |
activeRemote (, bool, ) |
| 469 |
Whether the remote replication consistency group is active |
| 470 |
|
| 471 |
|
| 472 |
abstractState (, str, ) |
| 473 |
The abstract state of the replication consistency group. |
| 474 |
|
| 475 |
|
| 476 |
localActivityState (, str, ) |
| 477 |
The state of activity of the local replication consistency group. |
| 478 |
|
| 479 |
|
| 480 |
remoteActivityState (, str, ) |
| 481 |
The state of activity of the remote replication consistency group.. |
| 482 |
|
| 483 |
|
| 484 |
inactiveReason (, int, ) |
| 485 |
The reason for the inactivity of the replication consistency group. |
| 486 |
|
| 487 |
|
| 488 |
rpoInSeconds (, int, ) |
| 489 |
The RPO value of the replication consistency group in seconds. |
| 490 |
|
| 491 |
|
| 492 |
replicationDirection (, str, ) |
| 493 |
The direction of the replication of the replication consistency group. |
| 494 |
|
| 495 |
|
| 496 |
disasterRecoveryState (, str, ) |
| 497 |
The state of disaster recovery of the local replication consistency group. |
| 498 |
|
| 499 |
|
| 500 |
remoteDisasterRecoveryState (, str, ) |
| 501 |
The state of disaster recovery of the remote replication consistency group. |
| 502 |
|
| 503 |
|
| 504 |
error (, int, ) |
| 505 |
The error code of the replication consistency group. |
| 506 |
|
| 507 |
|
| 508 |
type (, str, ) |
| 509 |
The type of the replication consistency group. |
| 510 |
|
| 511 |
|
| 512 |
|
| 513 |
|
| 514 |
|
| 515 |
|
| 516 |
Status |
| 517 |
------ |
| 518 |
|
| 519 |
|
| 520 |
|
| 521 |
|
| 522 |
|
| 523 |
Authors |
| 524 |
~~~~~~~ |
| 525 |
|
| 526 |
- Trisha Datta (@Trisha-Datta) <[email protected]> |
| 527 |
- Jennifer John (@Jennifer-John) <[email protected]> |
| 528 |
|