AWS Builder Center: Learn, Build and Connect with builders in the AWS community
AWS Builder Center is the official home for builders on AWS. Share and read what others are working on, follow people who inspire you, explore training and workshops, and find tools to support what you're building.
How do I protect my data against accidental Amazon EC2 instance termination?
2 minute read
0
I want to know how to protect my data against accidental Amazon Elastic Compute Cloud (Amazon EC2) instance termination. I also want to troubleshoot and collect more information about probable termination causes and behaviors.
Resolution
Activate termination protection
Termination protection prevents an EC2 instance from accidental termination. By default, Amazon EC2 deactivates this option for instances. To protect your instance from unintentional termination, activate termination protection.
Create an Amazon Machine Image (AMI) to capture the data on all the Amazon EBS volumes that you attached to the instance. You can also use the AMI to launch a new instance.
Recreate your instance or restore data from a terminated instance