How do I restore or recover a terminated Amazon EC2 instance?
Last updated: 2019-10-08
My Amazon Elastic Compute Cloud (Amazon EC2) instance was terminated, but I need to recover or restore data from that instance. How can I recover or restore the data?
As part of an Amazon EC2 instance termination, the data on any instance store volumes associated with that instance is deleted. By default, the root Amazon Elastic Block Storage (Amazon EBS) volume is automatically deleted.
After an Amazon EC2 instance is terminated, it's not possible to recover either the original Amazon EC2 instance or any volumes that were deleted as part of the termination process.
Also, if there are any remaining Amazon EBS volumes from the Amazon EC2 instance that weren't deleted as part of the termination process, then you can attach those to another Amazon EC2 instance. You can then access the data contained in those volumes.
In addition to regularly taking snapshots and AMIs to back up critical data, consider using termination protection to help prevent this issue in the future. You can also automate snapshots with Amazon Data Lifecycle Manager (Amazon DLM) and AWS Backup Service.