cloudformation-coverage-roadmap icon indicating copy to clipboard operation
cloudformation-coverage-roadmap copied to clipboard

RDS storage increase of less than 10% puts stack in inconsistent state

Open emspoars opened this issue 3 years ago • 0 comments

Name of the resource

AWS::RDS::DBInstance

Resource Name

No response

Issue Description

Currently RDS requires that storage be increased by at least 10% of its current size. From

https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_PIOPS.StorageTypes.html

we have

"When you increase the allocated storage, it must be by at least 10 percent. If you try to increase the value by less than 10 percent, you get an error."

When someone tries to perform an increment of less than 10% using the RDS console, all is well since a proper error message is shown and no actual changes are made.

However, if the change is made with Cloudformation, it puts the stack in an inconsistent state ("UPDATE ROLLBACK FAILED") that requires manual intervention (selecting "continue update rollback" and skipping the database).

I may me mistaken, but it seems Cloudformation is actually trying to "roll back" to the new value instead of the old value, since the error messages for update failure and rollback failure are the same:

"Invalid storage size for engine name mysql and storage type gp2: 21"

Please correct me if I'm mistaken, but it's my understanding that Cloudformation COULD keep the stack consistent in this case, since the database wasn't actually changed.

Expected Behavior

Stack should be in a consistent state, since no actual changes to the database are performed

Observed Behavior

Cloudformation leaves the stack in "update rollback failed" state

Test Cases

  • Create stack with RDS instance (AWS::RDS::DBInstance) and 20 (GB) for AllocatedStorage
  • Try to increase AllocatedStorage to 21

Other Details

No response

emspoars avatar Sep 08 '22 01:09 emspoars