Loading...
Loading...
### Terraform Version ```shell Terraform v1.9.2 on darwin_amd64 + provider registry.terraform.io/hashicorp/aws v5.63.0 ``` ### Terraform Configuration Files ```terraform resource "aws_db_instance" "example_db" { # this is being changed via blue_green_update parameter_group_name = "new-parameter-group" # DB with "db.t4g.medium" here has succeeded. This one fails to update instance_class = "db.m5.xlarge" engine = "postgres" db_name = "testdb" identifier = "example-db" allocated_storage = 100 publicly_accessible = false storage_type = "gp2" vpc_security_group_ids = [aws_security_group.example.id] skip_final_snapshot = true blue_green_update { enabled = true } } ``` ### Debug Output ``` Error: updating RDS DB Instance (example-db): creating Blue/Green Deployment: waiting for Green environment: unexpected state 'storage-initialization', wanted target 'available, storage-optimization'. last error: %!s() ``` ### Expected Behavior Terraform should anticipate the `storage-initialization` state after creation of the "green" side of the deploy. It is an expected and [documented](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/blue-green-deployments-creating.html#blue-green-deployments-creating-lazy-loading) state during blue/green deploys. Not all instance types will trigger the state. T-family instances will skip initialization, thus they don't trigger this bug. ### Actual Behavior Immediately following the creation of the "green" instance, terraform sees the `storage-initialization` state and begins deletion of the blue_green_update. ### Steps to Reproduce 1. `terraform init` 2. `terraform apply` 3. Change parameter group name 4. `terraform apply` ### Additional Context [This PR](https://github.com/hashicorp/terraform-provider-aws/pull/41275) may have already solved the issue, but it needs reviewing and merging. Note that this bug is NOT a duplicate of `storage-optimization` issues like [this one](https://github.com/hashicorp/terraform/issues/16740). That usually refers to changes in `storage_type`, whereas this is strictly related to lazy-loading after restoration from backups (which are utilized in blue/green). ### References https://github.com/hashicorp/terraform-provider-aws/pull/41275 ### Generative AI / LLM assisted development? _No response_
Click on a version to see all relevant bugs
Terraform Integration
Learn more about where this data comes from
Bug Scrub Advisor
Streamline upgrades with automated vendor bug scrubs
BugZero Enterprise
Wish you caught this bug sooner? Get proactive today.