ETH Zürich · Master's thesis · 2024 · Published at SOSP '25
Sailor: automating LLM training in the Cloud
PyTorchDeepSpeedGKEDockerSpot instances
The problem
Training large language models in the Cloud is expensive. The cheapest GPUs are spot (preemptible) instances, often 60–90% cheaper than on-demand ones, but the provider can reclaim them at any moment. Most training systems handle that badly: losing one node crashes the whole job, and recovery means restarting from a checkpoint in remote storage.
What Sailor does
Sailor automates ML training in the Cloud. Its core is an elastic, fault-tolerant runtime that keeps training going as nodes come and go: a master controller keeps track of every cluster, and when the set of nodes changes it pushes a new topology to each one.
My role
For my master's thesis I designed and built Sailor's elastic, fault-tolerant runtime: everything on this page, from in-memory checkpoints to recovering from a preemption. I also worked on Sailor's resource planner, which chooses a cost-effective cluster setup for a training job; this page focuses on the runtime.
One master controller coordinates training across GKE clusters in different regions
Recovering from a preemption
Checkpoints live in CPU memory instead of on disk or remote storage, with a full copy on a reliable on-demand node. When a spot node is preempted, a controller reconfigures the surviving nodes in place instead of restarting the job. The video walks through one recovery.
How Sailor recovers when a spot node disappears, followed by measured results (56 s, no sound)
Catch the error. Instead of crashing, every surviving process catches the failure and pauses.
Get the new config. The controller computes the new topology and tells every node its new rank and world size.
Recover the checkpoint. Each node pulls its shard from the on-demand node's memory, not from remote storage.
Clean up. Stale connections and error state from the old setup are cleared.
Restart training. Training resumes on the remaining nodes from the recovered state.
For a 1.5B-parameter model on 8 nodes in one GCP region, training is running again 52 seconds after a preemption: 10 s to re-initialise the distributed group, 26 s to restart DeepSpeed and 16 s to recover the snapshot.
Results
2.87× higher goodput on preemptible VMs than state-of-the-art fault-tolerance methods
Back to training in under a minute after a preemption (52 s for a 1.5B-parameter model)
Why it matters
Spot instances are only a bargain if training survives losing them. Making recovery fast and automatic turns that discount into real savings, so the same budget trains larger models.
Paper and code
Sailor was published at SOSP '25. The work is continued by the Efficient Architectures and Systems Lab (EASL) at ETH Zürich, and the code is open source.