Files
nexus/wiki/concepts/Spot-Instances.md
2026-04-24 16:03:17 +08:00

41 lines
1.8 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
title: "Spot Instances"
type: concept
tags:
- AWS
- Cost-Optimization
- FinOps
sources:
- public-cloud-learning-sessions-reducing-cloud-costs-20250318-170100-meeting-reco
- ctp-topic-13-cloud-finops-policies
last_updated: 2026-04-24
---
# Spot Instances
AWS 竞价实例,通过使用闲置的 EC2 容量以大幅折扣价格提供计算资源。
## Definition
Spot Instances 是 AWS EC2 的一种定价模型允许用户以按需价格On-Demand Price最高 **90% 的折扣** 申请使用空闲计算容量。当 AWS 需要回收容量时Spot 实例会在 2 分钟警告后被中断。
## Key Characteristics
- **折扣幅度**:相比 On-Demand 价格最高可享 90% 折扣
- **适用场景**容错工作负载——大数据处理、CI/CD 流水线、Web 服务器、HPC高性能计算
- **中断风险**AWS 可随时中断需应用层实现容错Checkpoint / 断点续传)
- **请求类型**One-Time一次性或 Persistent持久需手动设置
- **启动行为**:可在中断后重新请求
## Use Cases in OpenText
根据 [[ctp-topic-13-cloud-finops-policies]],研发环境三合一优化方案之一即为 Spot 实例,用于非关键工作负载的突发计算需求。
## Best Practices
1. **架构容错**:设计应用支持中断重启(如 Checkpoint 机制)
2. **组合策略**:配合 Savings Plans 用于基准负载Spot 用于弹性扩展部分
3. **实例类型选择**:选择多样化实例类型提高可用性
4. **监控中断**:使用 CloudWatch 监控 Spot 实例中断通知
## Connections
- [[Cloud Cost Optimization]] — Spot Instances 是云成本优化的核心手段之一
- [[Savings Plans]] — 与 Savings Plans 组合使用,实现"基准用 RI/SP + 弹性用 Spot"的最佳成本架构
- [[Right Sizing]] — 先完成 Right Sizing 再引入 Spot避免浪费