| « PreviousNext » | |
![]() ![]() ![]() | Did this page help you? Yes | No | Tell us about it... |
Amazon Elastic Block Store (Amazon EBS) can be an effective way to store data that you otherwise might lose when your Spot Instance terminates.
Important
Although Spot Instances can use Amazon EBS-backed AMIs, be aware that Spot Instances do not support the Stop/Start feature. In other words, you can't stop and start Spot Instances launched from an AMI that has an Amazon EBS root device. For information about Amazon EBS, see Amazon Elastic Block Store (Amazon EBS).
To set up the persistence of Spot Instance data, you map the Spot Instances that will be launched to
an existing Amazon Elastic Block Store (Amazon EBS) snapshot. Set the delete-on-termination
flag to false; this indicates that Amazon EC2 shouldn't delete the Amazon EBS volume when the spot instance terminates.
Let's walk through making an example Spot request with the following specifications:
Bid price of $0.500
One instance of the m1.xlarge instance type
Block device mapping to a snapshot that shouldn't be deleted when the Spot Instance is terminated
You can do this example using either the CLI or API tools. Using the CLI, your example request should look like this:
PROMPT>ec2-request-spot-instances -p 0.5 -t m1.xlarge -n 1 -b '/dev/sdb=snap-a123bcde:20:false' ami-8e1fece7
For more information, see: