AWS::RDS::OptionGroup
The AWS::RDS::OptionGroup
resource creates or updates an option group, to enable and
configure features that are specific to a particular DB engine.
Syntax
To declare this entity in your AWS CloudFormation template, use the following syntax:
JSON
{ "Type" : "AWS::RDS::OptionGroup", "Properties" : { "EngineName" :
String
, "MajorEngineVersion" :String
, "OptionConfigurations" :[ OptionConfiguration, ... ]
, "OptionGroupDescription" :String
, "OptionGroupName" :String
, "Tags" :[ Tag, ... ]
} }
YAML
Type: AWS::RDS::OptionGroup Properties: EngineName:
String
MajorEngineVersion:String
OptionConfigurations:- OptionConfiguration
OptionGroupDescription:String
OptionGroupName:String
Tags:- Tag
Properties
EngineName
-
Specifies the name of the engine that this option group should be associated with.
Valid Values:
-
mariadb
-
mysql
-
oracle-ee
-
oracle-ee-cdb
-
oracle-se2
-
oracle-se2-cdb
-
postgres
-
sqlserver-ee
-
sqlserver-se
-
sqlserver-ex
-
sqlserver-web
Required: Yes
Type: String
Update requires: Replacement
-
MajorEngineVersion
-
Specifies the major version of the engine that this option group should be associated with.
Required: Yes
Type: String
Update requires: Replacement
OptionConfigurations
-
A list of all available options for an option group.
Required: Conditional
Type: Array of OptionConfiguration
Update requires: No interruption
OptionGroupDescription
-
The description of the option group.
Required: Yes
Type: String
Update requires: Replacement
OptionGroupName
-
The name of the option group to be created.
Constraints:
-
Must be 1 to 255 letters, numbers, or hyphens
-
First character must be a letter
-
Can't end with a hyphen or contain two consecutive hyphens
Example:
myoptiongroup
If you don't specify a value for
OptionGroupName
property, a name is automatically created for the option group.Note
This value is stored as a lowercase string.
Required: No
Type: String
Update requires: Replacement
-
-
Tags to assign to the option group.
Required: No
Type: Array of Tag
Update requires: No interruption
Return values
Ref
When you pass the logical ID of this resource to the intrinsic Ref
function, Ref
returns the name of the option group.
For more information about using the Ref
function, see Ref
.
Examples
Create an option group with multiple option configurations
The following example creates an option group with two option configurations
(OEM
and APEX
). For more information about these
options, see Adding options to Oracle DB instances
in the Amazon RDS User Guide.
JSON
{ "OracleOptionGroup": { "Type": "AWS::RDS::OptionGroup", "Properties": { "EngineName": "oracle-ee", "MajorEngineVersion": "12.1", "OptionGroupDescription": "A test option group", "OptionConfigurations": [ { "OptionName": "OEM", "DBSecurityGroupMemberships": [ "default" ], "Port": "5500" }, { "OptionName": "APEX" } ] } } }
YAML
--- OracleOptionGroup: Type: AWS::RDS::OptionGroup Properties: EngineName: oracle-ee MajorEngineVersion: "12.1" OptionConfigurations: - DBSecurityGroupMemberships: - default OptionName: OEM Port: "5500" - OptionName: APEX OptionGroupDescription: A test option group
Create an option group with multiple option settings
The following example creates an option group that specifies two option settings
for the MEMCACHED
option. For more information about this option, see
MySQL
memcached support in the Amazon RDS User
Guide.
JSON
{ "SQLOptionGroup": { "Type": "AWS::RDS::OptionGroup", "Properties": { "EngineName": "mysql", "MajorEngineVersion": "8.0", "OptionGroupDescription": "A test option group", "OptionConfigurations": [ { "OptionName": "MEMCACHED", "VpcSecurityGroupMemberships": [ "sg-a1238db7" ], "Port": "1234", "OptionSettings": [ { "Name": "CHUNK_SIZE", "Value": "32" }, { "Name": "BINDING_PROTOCOL", "Value": "ascii" } ] } ] } } }
YAML
--- SQLOptionGroup: Properties: EngineName: mysql MajorEngineVersion: "8.0" OptionConfigurations: - OptionName: MEMCACHED OptionSettings: - Name: CHUNK_SIZE Value: "32" - Name: BINDING_PROTOCOL Value: ascii Port: "1234" VpcSecurityGroupMemberships: - sg-a1238db7 OptionGroupDescription: "A test option group" Type: AWS::RDS::OptionGroup
Microsoft SQL Server native backup and restore option
The following example creates an option group that specifies the Microsoft SQL Server native backup and restore option. For more information about this option, see Support for Native Backup and Restore in SQL Server in the Amazon RDS User Guide.
JSON
{ "myOptionGroup": { "Type": "AWS::RDS::OptionGroup", "Properties": { "EngineName": "sqlserver-se", "MajorEngineVersion": "12.00", "OptionGroupDescription": "SQL Server Native Backup and Restore", "OptionConfigurations": [ { "OptionName": "SQLSERVER_BACKUP_RESTORE", "OptionSettings": [ { "Name": "IAM_ROLE_ARN", "Value": "arn:aws:iam::333333333333333:role/service-role/sqlserverrestore" } ] } ] } } }
YAML
--- myOptionGroup: Type: 'AWS::RDS::OptionGroup' Properties: EngineName: sqlserver-se MajorEngineVersion: '12.00' OptionGroupDescription: SQL Server Native Backup and Restore OptionConfigurations: - OptionName: SQLSERVER_BACKUP_RESTORE OptionSettings: - Name: IAM_ROLE_ARN Value: 'arn:aws:iam::333333333333333:role/service-role/sqlserverrestore'