Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

AWS::MemoryDB::SubnetGroup

Focus mode
AWS::MemoryDB::SubnetGroup - AWS CloudFormation
Filter View

Specifies a subnet group. A subnet group is a collection of subnets (typically private) that you can designate for your clusters running in an Amazon Virtual Private Cloud (VPC) environment. When you create a cluster in an Amazon VPC, you must specify a subnet group. MemoryDB uses that subnet group to choose a subnet and IP addresses within that subnet to associate with your nodes. For more information, see Subnets and subnet groups.

Syntax

To declare this entity in your AWS CloudFormation template, use the following syntax:

JSON

{ "Type" : "AWS::MemoryDB::SubnetGroup", "Properties" : { "Description" : String, "SubnetGroupName" : String, "SubnetIds" : [ String, ... ], "Tags" : [ Tag, ... ] } }

YAML

Type: AWS::MemoryDB::SubnetGroup Properties: Description: String SubnetGroupName: String SubnetIds: - String Tags: - Tag

Properties

Description

A description of the subnet group.

Required: No

Type: String

Update requires: No interruption

SubnetGroupName

The name of the subnet group to be used for the cluster.

Required: Yes

Type: String

Pattern: [a-z][a-z0-9\-]*

Update requires: Replacement

SubnetIds

A list of Amazon VPC subnet IDs for the subnet group.

Required: Yes

Type: Array of String

Update requires: No interruption

Tags

An array of key-value pairs to apply to this resource.

For more information, see Tag.

Required: No

Type: Array of Tag

Maximum: 50

Update requires: No interruption

Return values

Fn::GetAtt

ARN

When you pass the logical ID of this resource to the intrinsic Ref function, Ref returns the ARN of the subnet group, such as arn:aws:memorydb:us-east-1:123456789012:subnetgroup/my-subnet-group

SupportedNetworkTypes

The network types supported by this subnet. Returns an array of strings that can include 'ipv4', 'ipv6', or both, indicating whether the subnet supports IPv4 only, IPv6 only, or dual-stack deployments.

Next topic:

Tag

Previous topic:

Tag

On this page

PrivacySite termsCookie preferences
© 2025, Amazon Web Services, Inc. or its affiliates. All rights reserved.