Skip to content

Latest commit

 

History

History
163 lines (143 loc) · 9.19 KB

replication_consistency_group.md

File metadata and controls

163 lines (143 loc) · 9.19 KB
title linkTitle page_title subcategory description
powerflex_replication_consistency_group data source
powerflex_replication_consistency_group
powerflex_replication_consistency_group Data Source - powerflex
This datasource is used to read the Replication Consistency Group entity of the PowerFlex Array. This feature is only supported for PowerFlex 4.5 and above.

powerflex_replication_consistency_group (Data Source)

This datasource is used to read the Replication Consistency Group entity of the PowerFlex Array. This feature is only supported for PowerFlex 4.5 and above.

Example Usage

/*
Copyright (c) 2024 Dell Inc., or its subsidiaries. All Rights Reserved.
Licensed under the Mozilla Public License Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
    http://mozilla.org/MPL/2.0/
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

# commands to run this tf file : terraform init && terraform apply
# This feature is only supported for PowerFlex 4.5 and above.

// Empty filter block will return all the replication conistancy group
data "powerflex_replication_consistency_group" "rcg" {}
output "rcgResult" {
  value = data.powerflex_replication_consistency_group.rcg
}

// If multiple filter fields are provided then it will show the intersection of all of those fields.
// If there is no intersection between the filters then an empty datasource will be returned
// For more information about how we do our datasource filtering check out our guides: https://dell.github.io/terraform-docs/docs/storage/platforms/powerflex/product_guide/examples/ 
data "powerflex_replication_consistency_group" "rcg_filter" {
  filter {
    # id = ["id", "id2"]
    # name = ["name-1", "name-2"]
    # remote_id = ["remote_id-1", "remote_id-2"]
    # rpo_in_seconds = [15]
    # protection_domain_id = ["protection_domain_id-1", "protection_domain_id-2"]
    # remote_protection_domain_id = ["remote_protection_domain_id-1", "remote_protection_domain_id-2"]
    # destination_system_id = ["destination_system_id-1", "destination_system_id-2"]
    # peer_mdm_id = ["peer_mdm_id-1", "peer_mdm_id-2"]
    # remote_mdm_id = ["remote_mdm_id-1", "remote_mdm_id-2"]
    # replication_direction = ["replication_direction-1", "replication_direction-2"]
    # curr_consist_mode = ["curr_consist_mode-1", "curr_consist_mode-2"]
    # freeze_state = ["freeze_state-1", "freeze_state-2"]
    # pause_mode = ["pause_mode-1", "pause_mode-2"]
    # lifetime_state = ["lifetime_state-1", "lifetime_state-2"]
    # snap_creation_in_progress = false
    # last_snap_group_id = ["last_snap_group_id-1", "last_snap_group_id-2"]
    # type = ["type-1", "type-2"]
    # disaster_recovery_state = ["disaster_recovery_state-1", "disaster_recovery_state-2"]
    # remote_disaster_recovery_state = ["remote_disaster_recovery_state-1", "remote_disaster_recovery_state-2"]
    # target_volume_access_mode = ["target_volume_access_mode-1", "target_volume_access_mode-2"]
    # failover_type = ["failover_type-1", "failover_type-2"]
    # failover_state = ["failover_state-1", "failover_state-2"]
    # active_local = false
    # active_remote = false
    # abstract_state = ["abstract_state-1", "abstract_state-2"]
    # error = [403]
    # local_activity_state = ["local_activity_state-1", "local_activity_state-2"]
    # remote_activity_state = ["remote_activity_state-1", "remote_activity_state-2"]
    # inactive_reason = [1]
  }
}
output "rcgResultFiltered" {
  value = data.powerflex_replication_consistency_group.rcg_filter
}

After the successful execution of above said block, we can see the output by executing terraform output command. Also, we can fetch information via the variable: data.powerflex_replication_conistancy_group.datasource_block_name.attribute_name where datasource_block_name is the name of the data source block and attribute_name is the attribute which user wants to fetch.

Schema

Optional

Read-Only

  • id (String) default datasource id
  • replication_consistency_group_details (Attributes List) List of Replication Consistency Group (see below for nested schema)

Nested Schema for filter

Optional:

  • abstract_state (Set of String) List of abstract_state
  • active_local (Boolean) Value for active_local
  • active_remote (Boolean) Value for active_remote
  • curr_consist_mode (Set of String) List of curr_consist_mode
  • destination_system_id (Set of String) List of destination_system_id
  • disaster_recovery_state (Set of String) List of disaster_recovery_state
  • error (Set of Number) List of error
  • failover_state (Set of String) List of failover_state
  • failover_type (Set of String) List of failover_type
  • freeze_state (Set of String) List of freeze_state
  • id (Set of String) List of id
  • inactive_reason (Set of Number) List of inactive_reason
  • last_snap_group_id (Set of String) List of last_snap_group_id
  • lifetime_state (Set of String) List of lifetime_state
  • local_activity_state (Set of String) List of local_activity_state
  • name (Set of String) List of name
  • pause_mode (Set of String) List of pause_mode
  • peer_mdm_id (Set of String) List of peer_mdm_id
  • protection_domain_id (Set of String) List of protection_domain_id
  • remote_activity_state (Set of String) List of remote_activity_state
  • remote_disaster_recovery_state (Set of String) List of remote_disaster_recovery_state
  • remote_id (Set of String) List of remote_id
  • remote_mdm_id (Set of String) List of remote_mdm_id
  • remote_protection_domain_id (Set of String) List of remote_protection_domain_id
  • replication_direction (Set of String) List of replication_direction
  • rpo_in_seconds (Set of Number) List of rpo_in_seconds
  • snap_creation_in_progress (Boolean) Value for snap_creation_in_progress
  • target_volume_access_mode (Set of String) List of target_volume_access_mode
  • type (Set of String) List of type

Nested Schema for replication_consistency_group_details

Read-Only:

  • abstract_state (String) Abstract State of the replication consistency group instance.
  • active_local (Boolean) Active Local of the replication consistency group instance.
  • active_remote (Boolean) Active Remote of the replication consistency group instance.
  • curr_consist_mode (String) Consistency Mode of the replication consistency group instance.
  • destination_system_id (String) Destination System ID of the replication consistency group instance.
  • disaster_recovery_state (String) Disaster Recovery State of the replication consistency group instance.
  • error (Number) Error of the replication consistency group instance.
  • failover_state (String) Failover State of the replication consistency group instance.
  • failover_type (String) Failover Type of the replication consistency group instance.
  • freeze_state (String) Freeze State of the replication consistency group instance.
  • id (String) Unique identifier of the replication consistency group instance.
  • inactive_reason (Number) Inactive Reason of the replication consistency group instance.
  • last_snap_group_id (String) Last Snap Group ID of the replication consistency group instance.
  • lifetime_state (String) Lifetime State of the replication consistency group instance.
  • local_activity_state (String) Local Activity State of the replication consistency group instance.
  • name (String) Name of the replication consistency group instance.
  • pause_mode (String) Pause Mode of the replication consistency group instance.
  • peer_mdm_id (String) Peer MDM ID of the replication consistency group instance.
  • protection_domain_id (String) Protection Domain ID of the replication consistency group instance.
  • remote_activity_state (String) Remote Activity State of the replication consistency group instance.
  • remote_disaster_recovery_state (String) Remote Disaster Recovery State of the replication consistency group instance.
  • remote_id (String) Remote ID of the replication consistency group instance.
  • remote_mdm_id (String) Remote MDM ID of the replication consistency group instance.
  • remote_protection_domain_id (String) Remote Protection Domain ID of the replication consistency group instance.
  • replication_direction (String) Replication Direction of the replication consistency group instance.
  • rpo_in_seconds (Number) rpoInSeconds of the replication consistency group instance.
  • snap_creation_in_progress (Boolean) Snap Creation In Progress of the replication consistency group instance.
  • target_volume_access_mode (String) Target Volume Access Mode of the replication consistency group instance.
  • type (String) Type of the replication consistency group instance.