powerflex_sds (Resource)

This resource can be used to manage Storage Data Servers on a PowerFlex array.

Note: Exactly one of protection_domain_name and protection_domain_id is required.

Caution: SDS creation or update is not atomic. In case of partially completed create operations, terraform can mark the resource as tainted. One can manually remove the taint and try applying the configuration (after making necessary adjustments). If the taint is not removed, terraform will destroy and recreate the resource.

Example Usage

/*
Copyright (c) 2023 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 plan && terraform apply
# Create, Update, Delete is supported for this resource
# To import , check sds_resource_import.tf for more info
# To create / update, either protection_domain_name or protection_domain_id must be provided
# name and ip_list are the required parameters to create or update
# other  atrributes like : performance_profile, port, drl_mode, rmcache_enabled, rfcache_enabled, rmcache_size_in_mb are optional 
# To check which attributes can be updated, please refer Product Guide in the documentation

resource "powerflex_sds" "create" {
  name                   = "demo-sds-test-01"
  protection_domain_name = "demo-sds-pd"
  ip_list = [
    {
      ip   = "10.10.10.12"
      role = "sdsOnly"
    },
    {
      ip   = "10.10.10.11"
      role = "sdcOnly"
    },
  ]
}

output "changed_sds" {
  value = powerflex_sds.create
}

Schema

Required

  • ip_list (Attributes Set) List of IPs to be assigned to the SDS. There must be at least one IP with all role or at least two IPs, one with role sdcOnly and the other with role sdsOnly. (see below for nested schema)
  • name (String) Name of SDS.

Optional

  • drl_mode (String) DRL mode of SDS
  • performance_profile (String) Performance Profile of SDS. Valid values are Compact and HighPerformance. Default value is determined by array settings.
  • port (Number) Port of SDS
  • protection_domain_id (String) ID of the Protection Domain under which the SDS will be created. Conflicts with protection_domain_name. Cannot be updated.
  • protection_domain_name (String) Name of the Protection Domain under which the SDS will be created. Conflicts with protection_domain_id. Cannot be updated.
  • rfcache_enabled (Boolean) Rfcache enabled state of SDS
  • rmcache_enabled (Boolean) Rmcache enabled state of SDS
  • rmcache_size_in_mb (Number) Read RAM cache size in MB of SDS. Can be set only when rmcache_enabled is true.

Read-Only

  • fault_set_id (String) Fault set id of SDS
  • id (String) The id of the SDS
  • is_on_vmware (Boolean) Is on vmware state of SDS
  • mdm_connection_state (String) Mdm connection state of SDS
  • membership_state (String) Membership state of SDS
  • num_of_io_buffers (Number) Number of io buffers of SDS
  • rmcache_frozen (Boolean) RMcache frozen state of SDS
  • rmcache_memory_allocation_state (String) Rmcache memory allocation state of SDS.
  • sds_state (String) State of SDS

Nested Schema for ip_list

Required:

  • ip (String) IP address to be assigned to the SDS.
  • role (String) Role to be assigned to the IP address. Valid values are all, sdcOnly and sdsOnly.

Import

Import is supported using the following syntax:

# Below are the steps to import SDS :
# Step 1 - To import a sds , we need the id of that sds 
# Step 2 - To check the id of the sds we can make use of sds datasource . Please refer sds_datasource.tf for more info.
# Step 3 - create a tf file with empty resource block . Refer the example below.
# Example :
# resource "powerflex_sds" "resource_block_name" {
# }
# Step 4 - execute the command: terraform import "powerflex_sds.resource_block_name" "id_of_the_sds" (resource_block_name must be taken from step 3 and id must be taken from step 2)
# Step 5 - After successful execution of the command , check the state file