What's the difference between instance store and EBS?

Last updated: 2022-07-19

I'm not sure whether to store the data associated with my Amazon EC2 instance in instance store or in an attached Amazon Elastic Block Store (Amazon EBS) volume. Which option is best for me?

Resolution

Some Amazon Elastic Compute Cloud (Amazon EC2) instance types come with a form of directly attached, block-device storage known as the instance store. The instance store is ideal for temporary storage, because the data stored in instance store volumes is not persistent through instance stops, terminations, or hardware failures.

For data you want to retain longer, or if you want to encrypt the data, use Amazon Elastic Block Store (Amazon EBS) volumes instead. EBS volumes preserve their data through instance stops and terminations, can be easily backed up with EBS snapshots, can be removed from one instance and reattached to another, and support full-volume encryption. To prevent unintentional changes or data loss, it's a best practice to perform regular snapshots, which can be automated with AWS Backup.

Note: In Amazon EBS, the DeleteOnTermination attribute for an instance's root volume is set to true by default. If this attribute is not changed, then the instance's root volume is deleted when the instance terminates. To change the DeleteOnTermination attribute to false, see How can I prevent my Amazon EBS volumes from being deleted when I terminate Amazon EC2 instances?


Did this article help?


Do you need billing or technical support?