Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AWS cloud formation delete failed

How can I force delete my AWS cloud formation stack? The tied resources were already deleted previously like the DNS, route53, etc. Whenever I delete the stack, it failed because it couldn't find the resources.

The specified hosted zone does not exist. DELETE_FAILED.

This made the deletion halt and made the stack still active. How can I force clean-up and remove this stack?

like image 878
Adrian M Avatar asked Apr 15 '14 06:04

Adrian M


People also ask

What will happen if I delete CloudFormation stack?

During deletion, CloudFormation deletes the stack but doesn't delete the retained resources. Retaining resources is useful when you can't delete a resource, such as a non-empty S3 bucket, but you want to delete the stack.


1 Answers

Based on this thread, it appears that stack deletion can be problematic if the stack is altered.

https://forums.aws.amazon.com/thread.jspa?threadID=71050&start=0&tstart=0

Looks like you need to go via Support to get it deleted.

That said, I have been able to delete stacks where I have manually altered the components. Sometimes you need to wait a couple of hours after you terminate instances, VPCs, subnets etc before the stack deletion actually succeeds.

like image 62
Garreth McDaid Avatar answered Sep 20 '22 23:09

Garreth McDaid