Spot Instances and Spot Fleets Flashcards
What is the maximum percent-off of on-demand pricing at which Spot Instances are offered?
Spot Instances are available at up to 90% off on-demand pricing.
What are some example use cases for Spot Instances?
Think use cases where you don’t need persistent storage
- Big Data
- Containerized Workloads
- CI/CD
- Web Servers
- HPC
- Image & Media Rendering
Under default settings, what happens to your spot instance if, while you are using it, the spot price goes above your spot price maximum?
You have 2 minutes to choose whether to stop or terminate the instance
What is a Spot Block?
A Spot Block allows you to stop your spot instance from being terminated even if the spot price goes over your maximum spot price.
For how long is a Spot Block set?
Currently, Spot Blocks can be set for between 1 and 6 hours
Why are Spot Instances not useful for persistent workloads?
Becuase your spot instance capacity can be terminated at any time (if the price goes above your max spot price)
What is the difference between the two types of Request Types for Spot Instances?
- For a one-time request type, when the spot price goes above and then back below your max, you don’t have your spot instance anymore
- For a persistent request type, when the spot price goes above and then back below your max, a spot instance will be auto-restarted.
(More specifically, for a persistent request type, when the spot price goes above your max, it will resubmit your Spot Request)
What are the fields of a Spot Request?
- Max Price
- # of instances desired
- Launch specs
- Request type
- Valid from & Valid until
What is a Spot Fleet?
A Spot Fleet is a collection of spot instances and, optionally, on-demand instances.
How does AWS select which types of instances are used to fill out your spot fleets?
- You set up launch pools, and can define things like EC2 Instance Type, AZ, and OS
- You can have multiple pools, and the fleet will choose the best way to implement depending on the strategy you define
- Spot fleets stop launching instances once you reach your price threshold or desired capacity
How does your AWS Spot Fleet respond if one its Spot Instances is interrupted?
- The Spot fleet attempts to maintain its target capacity fleet if your spot instances are interrupted.
When does AWS stop assigning new instances to your spot fleet?
Once you have reached your price threshold OR your desired capacity
What are the four types of spot fleet strategies?
- capacityOptimized - come from pool with optimal capacity for number of instances launching (think trying to go for fewest interruptions)
- lowestPrice - (default) Spot Instances are selected to come from the lowest price.
- diversified - Spot Instances are selected to be distributed evenly across all spot pools
- InstancePoolsToUseCount - used in conjunction with lowestprice, Spot Instances are selected to be distrubtuted evenly across a user-selected set of spot pools
What is a Spot Instance Pool?
A set of unused EC2 instances with the same instance type, operating system, Availability Zone, and network platform.
Why would you ever pick the capacityOptimized Spot Fleet Strategy over lowestPrice?
- Capacity-optimized is better for workloads with a high cost of interruption.