Spot VM preemption, zero lost work: idempotency and checkpoint/restart in practice
rseroter · x · 2026-12-04
Engineer Casey West's "Designed for Flexibility" Part 4 (9-min read) shows how to run long-running ML jobs on Google Spot VMs without losing progress on preemption.
- He deliberately forced preemptions on two workloads (a CPU queue worker with 5,000 tasks; a GPU embedding job over 50,000 text chunks) — both passed with zero lost work.
- Two classic distributed-systems patterns do the job: an idempotent receiver and checkpoint/restart.
- Reproduction: gcloud compute instances simulate-maintenance-event on one node; companion repo cwest/gke-spot-playbook.
- Builds on Part 3's machine-type/region ranking — this post covers the interruption half of running on Spot.
Takeaway: saving money on Spot doesn't cost reliability if jobs are designed for interruption.
More from Infra
- MedGemma 2 ships in two sizes: 26B server MoE and offline-capable E4B for phones — GoogleDeepMind · 2026-12-04
- Nvidia cut off Malaysia's Megaspeed in June 2025 after it resisted chip inspections, Huang says — TechCrunch AI · 2026-12-04
- MiniCPM5 hits 52 tok/s on a phone — but 30 tok/s once squeezed to 3GB — AIFlow_ML · 2026-12-04
- Baseten raises $3B Series G at $30B valuation with NDR over 400% — saranormous · 2026-12-04
- Huang testimony clash: Megaspeed no-sell listing vs. 'counted every GPU' claim — ShakeelHashim · 2026-12-04
- Predicting the PQC rollout: OS updates, free cloud certificates, insecure-crypto toggles — kingslyj · 2026-12-04