Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Error: rebooting RDS Cluster Instance: InvalidDBInstanceState: Instance cannot currently reboot due to an in-progress management operation. #27325

Open
MarinaBukataya opened this issue Oct 19, 2022 · 3 comments
Labels
bug Addresses a defect in current functionality. service/rds Issues and PRs that pertain to the rds service. stale Old or inactive issues managed by automation, if no further action taken these will get closed.

Comments

@MarinaBukataya
Copy link

MarinaBukataya commented Oct 19, 2022

Terraform Core Version

1.1.3

AWS Provider Version

4.35.0

Affected Resource(s)

module.rds_aurora.aws_rds_cluster_instance

Expected Behavior

Cluster with two replicas created and rebooted

Actual Behavior

Cluster with two tainted replicas created, failed to reboot

Relevant Error/Panic Output Snippet

No response

Terraform Configuration Files

module "rds_aurora" {
  source  = "terraform-aws-modules/rds-aurora/aws"
  version = "7.5.1"

  name                   = local.cluster_id

  snapshot_identifier    = try(data.aws_db_cluster_snapshot.start_from_snapshot[0].id, null)

  engine                 = "aurora-mysql"
  engine_version         = var.rds_engine_version
  engine_mode            = "provisioned"
  ca_cert_identifier     = "rds-ca-2019-eu-south-1"

  vpc_id                 = local.vpc_id
  db_subnet_group_name   = aws_db_subnet_group.rds-subnet-group.name
  subnets                = local.private_subnet_ids
  create_db_subnet_group = false

  master_username        = var.rds_master_username
  master_password        = var.rds_master_password
  create_random_password = false

  instance_class           = var.rds_instance_type
  instances = {
    1 = {}
    2 = {}
  }
  storage_encrypted        = true
  db_parameter_group_name         = aws_db_parameter_group.rds-instance-params.name
  db_cluster_parameter_group_name = aws_rds_cluster_parameter_group.rds-cluster-params.name
  create_security_group  = false
  vpc_security_group_ids = concat([aws_security_group.rds_inbound.id], var.external_sgs)

  apply_immediately               = true
  skip_final_snapshot             = true
  auto_minor_version_upgrade      = false
  deletion_protection             = var.deletion_protection
  backup_retention_period         = var.backup_retention_period
  enabled_cloudwatch_logs_exports = var.rds_cloudwatch_logs
  kms_key_id                      = data.aws_kms_alias.rds_kms_key.arn

  tags = merge(
    local.common_tags,
    {
      Description = "RDS cluster ${var.rds_cluster_number}"
    }
  )

}

or

resource "aws_rds_cluster" "aurora_cluster" {

  cluster_identifier     = local.cluster_id
  final_snapshot_identifier       = try(data.aws_db_cluster_snapshot.start_from_snapshot[0].id, null)
  engine                 = "aurora-mysql"
  engine_version         = var.rds_engine_version
  engine_mode            = "provisioned"
  master_username        = var.rds_master_username
  master_password        = var.rds_master_password
  db_subnet_group_name   = aws_db_subnet_group.rds-subnet-group.name
  vpc_security_group_ids = concat([aws_security_group.rds_inbound.id], var.external_sgs)
  apply_immediately               = true
  skip_final_snapshot             = true
  deletion_protection             = var.deletion_protection
  backup_retention_period         = var.backup_retention_period
  enabled_cloudwatch_logs_exports = var.rds_cloudwatch_logs
  kms_key_id                      = data.aws_kms_alias.rds_kms_key.arn
  storage_encrypted        = true
  db_cluster_parameter_group_name = aws_rds_cluster_parameter_group.rds-cluster-params.name
  db_instance_parameter_group_name = aws_db_parameter_group.rds-instance-params.name
  
  lifecycle {
            create_before_destroy = true
        }
}

resource "aws_rds_cluster_instance" "aurora_cluster_instance" {
    identifier            = "${local.cluster_id}-1"
    engine                = "aurora-mysql"
    cluster_identifier    = local.cluster_id
    ca_cert_identifier     = "rds-ca-2019-eu-south-1"
    instance_class        = var.rds_instance_type
    apply_immediately     = true
    
}

Steps to Reproduce

Create RDS cluster and RDS cluster instances in AWS Milan region

Debug Output

Link to debug output

Panic Output

No response

Important Factoids

No response

References

No response

Would you like to implement a fix?

No response

@MarinaBukataya MarinaBukataya added bug Addresses a defect in current functionality. needs-triage Waiting for first response or review from a maintainer. labels Oct 19, 2022
@github-actions
Copy link

Community Note

Voting for Prioritization

  • Please vote on this issue by adding a 👍 reaction to the original post to help the community and maintainers prioritize this request.
  • Please see our prioritization guide for information on how we prioritize.
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.

Volunteering to Work on This Issue

  • If you are interested in working on this issue, please leave a comment.
  • If this would be your first contribution, please review the contribution guide.

@github-actions github-actions bot removed the bug Addresses a defect in current functionality. label Oct 19, 2022
@ewbankkit ewbankkit added bug Addresses a defect in current functionality. service/rds Issues and PRs that pertain to the rds service. and removed needs-triage Waiting for first response or review from a maintainer. labels Oct 19, 2022
@MarinaBukataya MarinaBukataya changed the title Error: rebooting RDS Cluster Instance: InvalidDBInstanceState: Instance cannot currently reboot due to an in-progress management operation. [Bug] Error: rebooting RDS Cluster Instance: InvalidDBInstanceState: Instance cannot currently reboot due to an in-progress management operation. Oct 19, 2022
@MarinaBukataya MarinaBukataya changed the title [Bug] Error: rebooting RDS Cluster Instance: InvalidDBInstanceState: Instance cannot currently reboot due to an in-progress management operation. [Bug]: Error: rebooting RDS Cluster Instance: InvalidDBInstanceState: Instance cannot currently reboot due to an in-progress management operation. Oct 19, 2022
@mlazlo
Copy link

mlazlo commented Oct 26, 2022

I am receiving the same error using version 1.3.0 on terraform tower:
Error: rebooting RDS Cluster Instance (dev-avsrep-eim-aurora-postgresql-0): InvalidDBInstanceState: Instance cannot currently reboot due to an in-progress management operation.
status code: 400, request id: 3f67c65c-a891-4a8d-b786-a620237becf4

Copy link

Marking this issue as stale due to inactivity. This helps our maintainers find and focus on the active issues. If this issue receives no comments in the next 30 days it will automatically be closed. Maintainers can also remove the stale label.

If this issue was automatically closed and you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thank you!

@github-actions github-actions bot added the stale Old or inactive issues managed by automation, if no further action taken these will get closed. label Oct 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Addresses a defect in current functionality. service/rds Issues and PRs that pertain to the rds service. stale Old or inactive issues managed by automation, if no further action taken these will get closed.
Projects
None yet
Development

No branches or pull requests

3 participants