Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><strong>Update: times have changed</strong></p> <p>EC2 Spot Instance requests can now be configured to <code>stop</code> instead of <code>terminate</code> an outbid spot instance or for any other capacity-related event that causes the spot instance to be interrupted.</p> <p>See <a href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-interruptions.html" rel="nofollow noreferrer">Interruption Behavior</a> in the EC2 Developer Guide. Certain classes of instances can also hibernate, with the appropriate agent installed.</p> <p>Note that this new feature does not guarantee that instances will continue to run, but only that they will restart with their previous EBS volumes, private IP, Elastic IP, and instance ID all intact.</p> <p>Previously answer follows:</p> <hr> <p>Spot <em>instances</em> cannot be persistent, but spot <em>requests</em> can. </p> <blockquote> <p>Persistent Spot Requests: When you specify a Spot bid request as "persistent", you ensure that it is automatically resubmitted after its instance is terminated—by you or by Amazon EC2—until you cancel the bid request. This enables you to automate launching Spot instances any time the Spot price is below your maximum price.</p> </blockquote> <p><a href="http://aws.amazon.com/ec2/spot-instances/#4" rel="nofollow noreferrer">http://aws.amazon.com/ec2/spot-instances/#4</a></p> <p>That keeps the machines running any time the price is within range, but as for the rest of it, consider what your spot instances are doing that has you thinking that persistence of the disks is the way to go. Think "cloud." Think "ephemeral." Spot instances are intended to be ephemeral machines that start up, fetch work, do work, commit work, and if they go away, the work is still out there waiting for the next instance to fetch it again, complete it, and commit it. You "can" use them with EBS and persist the volume, but if you do, those instances cannot be restarted (as you have noticed). </p> <p>If your AMI uses the instance store, and stores everything that needs to be persistent externally (in S3, for example) then you don't need to hack around the AWS architecture and you can sit back and watch your machines fire up when the price is right, do their work, and shut down again when the prices go out of range. And, no bit rot, because every boot is a shiny clean system. </p> <p>Or, your instance(s) could mount NFS shares exported by a machine that's always on.</p> <p>Or this: <a href="https://serverfault.com/questions/448043/auto-attach-ebs-volume-to-a-new-spot-instance">https://serverfault.com/questions/448043/auto-attach-ebs-volume-to-a-new-spot-instance</a></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload