aws-cloudformation / aws-cloudformation/cloudformation-coverage-roadmap

Cross region [AWS::RDS::DBInstance] read replica fails to create with mysql parameter [lower_case_table_names]

Open
#1,724 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
No language data
Stars
1.1k
Forks
62
PR merge metrics
No merged PRs in 30d

Description

### Name of the resource

AWS::RDS::DBInstance

### Resource Name

_No response_

### Issue Description

Unable to create a read replica from cross region with the parameter `lower_case_table_names` because CFN first creates the default DBParameterGroup and then it is modified after it is created.

MySQL parameter `lower_case_table_names` cannot be modified as we see in in [Known issues and limitations for Amazon RDS for MySQL](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/MySQL.KnownIssuesAndLimitations.html#MySQL.Concepts.ParameterNotes) .

```
When a parameter group is associated with a version 8.0 MySQL DB instance, you can't modify the lower_case_table_names parameter in the parameter group.
```
Due to this limitation, we cannot create a cross region replica with the parameter `lower_case_table_names`.

### Expected Behavior

Be able to create a cross region replica with the parameter `lower_case_table_names`.

### Observed Behavior

Error
```
Resource handler returned message: "DB Instance is in state: incompatible-restore"
```

### Test Cases

Create a read replica using the following template
```
Resources:
MyDB1:
Type: 'AWS::RDS::DBInstance'
Properties:
SourceDBInstanceIdentifier: arn:aws:rds:::db:
StorageType: gp2
DBInstanceClass: 'db.m5.large'
AllocatedStorage: 20
Engine: mysql
EngineVersion: '8.0.32'
MasterUsername: XXXXX
MasterUserPassword: XXXXX
DBParameterGroupName: !Ref DBParameterGroup
DBParameterGroup1:
Type: AWS::RDS::DBParameterGroup
Properties:
Description: MySQL parameters
Family: 'mysql8.0'
Parameters:
lower_case_table_names: '1'
```

### Other Details

_No response_

Contributor guide

Open the contributing guide

Research direction

Reproduce the failure with the supplied AWS::RDS::DBInstance and AWS::RDS::DBParameterGroup template, using a MySQL 8.0 cross-region read replica and lower_case_table_names set to 1. Start by tracing how the parameter group is created and modified during replica creation. Done means the replica creates successfully without the incompatible-restore error.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, mysql
Domain
cloud, databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.