Reputation: 101
Trying to create an RDS Aurora serverless with MySQL 2.07.1 and got an error:
"The engine mode serverless you requested is currently unavailable. (Service: AmazonRDS; Status Code: 400; Error Code: InvalidParameterValue; Request ID: xxxx; Proxy: null)"
Any suggestions would help me a lot
here is the sample code
{
"AWSTemplateFormatVersion" : "2010-09-09",
"Description" : "AWS CloudFormation Sample Template AuroraServerlessDBCluster: Sample template showing how to create an Amazon Aurora Serverless DB cluster. **WARNING** This template creates an Amazon Aurora DB cluster. You will be billed for the AWS resources used if you create a stack from this template.",
"Parameters" : {
"DBUsername" : {
"NoEcho" : "true",
"Description" : "Username for MySQL database access",
"Type" : "String",
"MinLength" : "1",
"MaxLength" : "16",
"AllowedPattern" : "[a-zA-Z][a-zA-Z0-9]*",
"ConstraintDescription" : "must begin with a letter and contain only alphanumeric characters."
},
"DBPassword" : {
"NoEcho" : "true",
"Description" : "Password MySQL database access",
"Type" : "String",
"MinLength" : "8",
"MaxLength" : "41",
"AllowedPattern" : "[a-zA-Z0-9]*",
"ConstraintDescription" : "must contain only alphanumeric characters."
}
},
"Resources" : {
"RDSCluster" : {
"Type": "AWS::RDS::DBCluster",
"Properties" : {
"MasterUsername" : {
"Ref": "DBUsername"
},
"MasterUserPassword" : {
"Ref": "DBPassword"
},
"DBClusterIdentifier" : "my-serverless-cluster",
"Engine" : "aurora",
"EngineVersion" : "2.07.1",
"EngineMode" : "serverless",
"ScalingConfiguration" : {
"AutoPause" : true,
"MinCapacity" : 4,
"MaxCapacity" : 32,
"SecondsUntilAutoPause" : 1000
}
}
}
}
}
Upvotes: 7
Views: 6777
Reputation: 21
You are trying to create RDS aurora serverless with Aurora MySQL 2.07.1 which is MySQL 5.7 version[+] a link.
Looking into the above code and template parameters, I can see that the Engine
parameter you have is aurora
and it should be aurora-mysql
for the MySQL 5.7 version [+] (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbcluster.html#cfn-rds-dbcluster-engine).
Upvotes: 2
Reputation: 433
To see which versions are available in serverless
mode, run this:
aws rds describe-db-engine-versions --engine aurora-mysql --filters Name=engine-mode,Values=serverless
And if you want to understand which DB versions are available according to the engine mode, just remove the filter:
aws rds describe-db-engine-versions --engine aurora-mysql
This way you will see what is possible in serverless
or provisioned
mode, and the supported DB versions for each.
Especially the SupportedEngineModes
blocks which generally look like:
"SupportedEngineModes": [
"serverless"
]
Or
"SupportedEngineModes": [
"provisioned"
]
Upvotes: 6
Reputation: 436
I think I used the same example from the docs, I made the same mistake when trying to use MySQL 5.7 instead of 5.6 from the example, and inevitably ran into the same issue.
The solution was to set:
"Engine": "aurora-mysql",
"EngineVersion": "5.7.mysql_aurora.2.07.1"
From further up in the same doc:
Engine
The name of the database engine to be used for this DB cluster.
Valid Values: aurora (for MySQL 5.6-compatible Aurora), aurora-mysql (for MySQL 5.7-compatible Aurora), and aurora-postgresql
Also from the same doc:
EngineVersion
The version number of the database engine to use.
...
To list all of the available engine versions for aurora-mysql (for MySQL 5.7-compatible Aurora), use the following command:
aws rds describe-db-engine-versions --engine aurora-mysql --query "DBEngineVersions[].EngineVersion"
Running that command using the AWS CLI yields something like:
[
...
"5.7.mysql_aurora.2.06.0",
"5.7.mysql_aurora.2.07.0",
"5.7.mysql_aurora.2.07.1",
"5.7.mysql_aurora.2.07.1",
"5.7.mysql_aurora.2.07.2",
"5.7.mysql_aurora.2.07.3",
...
]
This lead me to believe the we needed to use the full Aurora MySQL version number.
Upvotes: 0