Open
Description
Terraform and AWS Provider Version
Terraform v1.9.7
on linux_amd64
+ provider registry.terraform.io/hashicorp/aws v5.96.0
Affected Resource(s) or Data Source(s)
aws_elasticache_replication_group
Expected Behavior
Able to successfully update/sync resource aws_elasticache_replication_group
after an import
Actual Behavior
Error on apply just after import:
Relevant Error/Panic Output
Error: modifying ElastiCache Replication Group (my-elasticache-replication-group) authentication: operation error ElastiCache: ModifyReplicationGroup, https response error StatusCode: 400, RequestID: 01234567-89ab-cdef-0123-456789abcdef, InvalidParameterCombination: Auth tokens can't be enabled with a user group already associated. Pass RemoveUserGroups to proceed.
with aws_elasticache_replication_group.self,
on main.tf line 19, in resource "aws_elasticache_replication_group" "self":
19: resource "aws_elasticache_replication_group" "self" {
Sample Terraform Configuration
Click to expand configuration
resource "aws_elasticache_replication_group" "self" {
replication_group_id = "my-elasticache-replication-group"
engine = "redis"
engine_version = "7.1"
cluster_mode = "disabled"
parameter_group_name = "my-elasticache-parameter-group"
user_group_ids = ["my-elasticache-user-group"]
lifecycle {
ignore_changes = [
auth_token_update_strategy,
]
}
}
Steps to Reproduce
terraform import 'aws_elasticache_replication_group.self' 'my-elasticache-replication-group'
terraform apply
Debug Logging
Click to expand log output
N/A
GenAI / LLM Assisted Development
n/a
Important Facts and References
- Supposed to be fix on 5.28.0: r/aws_elasticache_replication_group: v2 state upgrader #34600
Would you like to implement a fix?
No