Skip to main content
  1. Projects/
  2. AWS DevOps Pro Certification/
  3. 4: Incident and Event Response/
  4. 1: Rollbacks/

0: CloudFormation Rollbacks

·1 min

Why do Stacks Fail?

  • Insufficient permissions (IAM error)
    • Need permissions for all the resources involved!
  • Limits exceeded: Too many instances, e.g.
  • So many possible reasons

Why would a rollback fail?

  • Drift
    • e.g. rolling back to an old (deleted) DB instance
  • Not using drift detection
  • Trying to delete parent stack before children in nested stacks

Troubleshooting Stack Failures:

  • Study the messages during stack creation
  • If EC2 issues:
    • Study cloud-init
    • Study logs in /var/log
    • Install cloudWatch logs agent, publish logs
  • If one resource is being persnickety:
    • Put it in RetainResources param
    • Delete stack; resource will be retained
    • Delete resource individually
  • S3:
    • Non-empty buckets won’t delete