Rolling Out a 500 GB Checkpoint to a 2,000-Node GPU Fleet
System DesignModel answerLast updated
Design a rack-aware pipeline that ships a 500 GB model to 2,000 GPU hosts within 20 minutes, with integrity checks, zero-downtime cutover, and automatic rollback.
Problem
Your team runs an LLM inference service on 2,000 GPU hosts (8 GPUs each, H100-class). A new release consists of a 500 GB bundle: sharded safetensors weights, tokenizer files, and configs. Releases happen often, and each one must reach every host and go live in 20 minutes or less, end to end.
Hosts sit in racks of 16 to 32 machines behind a top-of-rack (ToR) switch. Bandwidth inside a rack is very high (400 to 800 Gbps per host), but links between racks across the spine are oversubscribed. Pulling straight from object storage (S3/GCS) on every host overloads both the egress path and the spine.
Design the system that distributes the bundle, validates it, switches traffic to the new version, and recovers if something goes wrong.
Requirements
Functional
- Copy the artifact from staging storage to all 2,000 hosts.
- Verify integrity of individual chunks while they are in transit, and of the whole artifact before it is loaded.
- Switch from the old version to the new one without dropping requests and without any model-parallel group serving mixed versions.
- Roll back quickly if validation fails, stragglers stall the rollout, or post-deploy health metrics regress.
Non-functional
- Total budget of 20 minutes covering download, verification, load, warm-up, and cutover.
- Hosts have local NVMe and 1 to 2 TB of RAM. An 8-GPU host cannot hold two full copies of the weights in VRAM.
What to cover
- Distribution topology. Compare central fan-out, a pipelined chain/ring, tree broadcast, and BitTorrent-style P2P. Pick one and justify it using the network layout.
- Chunking and integrity. Chunk sizing, indexing, checksums, and reuse of unchanged data across versions.
- Topology awareness. How to use intra-rack bandwidth heavily while capping spine usage.
- Orchestration and atomic cutover. NVMe staging, preloading into host RAM or VRAM, and zero-downtime switching for tensor/pipeline-parallel groups.
- Failure handling. Stragglers, nodes dying mid-transfer, corrupt chunks, and fast rollback.
Back your choices with rough numbers.
Hints
Hint 1
Start with arithmetic: total bytes delivered (nodes x artifact size) versus what one origin or the spine can push. This quickly rules out central fan-out and shows how much a one-copy-per-rack scheme saves.
Hint 2
Combine approaches in layers: a small tree over the spine to get one copy into each rack, then a pipelined peer swarm inside each rack. Forward chunks as soon as they are verified so stages overlap instead of running sequentially.
Hint 3
Treat a model-parallel group as the unit of cutover. Think about prepare, drain, swap, and commit steps with a version epoch, canary first, then waves limited by spare serving capacity and gated by health checks.
Hint 4
VRAM cannot hold both versions, so decide where the new weights wait (host RAM) and how the old version stays available for rollback (NVMe, ideally RAM too).
Model answer
Hard Try it yourself first — then compare your approach, complexity and edge cases.
1. Quantify first
- Total delivered: 2,000 x 500 GB = 1 PB.
- Central pull: even with an optimistic 1 Tbps (125 GB/s) from object storage, 1 PB takes about 8,000 s, over two hours, and it hammers the spine. Rejected.
- Per-node floor: a 400 Gbps NIC moves 50 GB/s, so about 10 s on the wire. Realistically NVMe write speed dominates (10 to 20 GB/s on striped drives), giving roughly 30 to 60 s per node.
- Racks: about 80 racks at 25 nodes each. If one copy enters each rack, spine traffic is 80 x 500 GB = 40 TB, a 25x cut versus 1 PB.
- Memory: 500 GB across 8 x 80 GB GPUs nearly fills VRAM, so old and new cannot coexist there. Stage the new version in host RAM and swap per serving group.
Suggested budget: distribution and streaming verification about 4 min, load to host RAM about 2, canary about 4, wave swaps about 6, slack about 4.
2. Topology comparison
| Option | Assessment |
|---|---|
| Central fan-out | Hours long, saturates origin and spine. |
| Single chain/ring | Near-optimal bandwidth (about S/B + (N-1)c/B) but one slow node stalls everything behind it, and it ignores racks. |
| Tree | Shallow and rack-aware, but interior nodes become bottlenecks and single points of failure. |
| Pure P2P | Self-healing, but naive peer choice sprays traffic across the spine and creates incast. |
Choice: hierarchical hybrid.
- Pull from object storage once into a regional cache tier.
- Run a tree across racks (fan-out about 4) between one or two seeders per rack, with a deploy-traffic cap on each rack uplink (say 100 Gbps).
- Inside each rack, run a peer swarm coordinated by a rack-local tracker.
Everything is pipelined at chunk level, so a node forwards chunk k while receiving chunk k+1. Time is roughly size / bottleneck rate plus depth x chunk time. At a 12.5 GB/s cross-rack cap that is about 40 s plus small depth latency; budget 2 to 4 minutes for real-world inefficiency.
3. Chunking, integrity, reuse
- Content-addressed chunks of 64 to 256 MB, aligned to tensor/shard boundaries, hashed with BLAKE3 or SHA-256. That gives a few thousand chunks per release: low tracker overhead, cheap retries.
- Signed, immutable manifest listing version, base version, chunk hashes, sizes, file offsets, and a Merkle root.
- Verify on arrival, before marking a chunk complete or serving it onward, so corruption cannot spread. Verify the Merkle root for the full artifact before loading.
- Assemble into a temp directory and atomically rename once complete.
- Dedup across versions: each host keeps a local content-addressed store of the last N versions and fetches only chunks missing from it. Tokenizers, configs, and frozen layers reuse fully. A full fine-tune changes nearly every tensor, so gains there are small. They are large for adapters and partial updates.
4. Orchestration and atomic cutover
The unit of serving is the model-parallel group (TP within a node, possibly PP across nodes). Atomic means each request is served by exactly one version and no group runs mixed versions.
- Stage: agent verifies chunks to NVMe, then preloads into pinned host RAM (mmap safetensors) and reports
STAGED_RAM. - Canary: swap one or two groups first. Check golden prompts (logit or perplexity drift versus reference), latency, and error rate.
- Waves with two-phase commit, each wave sized to spare capacity (5 to 10% of groups):
- Prepare: every group member confirms the staged version and Merkle root. Any "no" or timeout aborts that group.
- Drain: the router stops sending new requests; in-flight ones finish up to a max-generation timeout; other groups absorb load.
- Swap: barrier, then host-to-GPU copy (about 62.5 GB per GPU; PCIe Gen5 makes this seconds), re-init NCCL communicators, capture CUDA graphs, run warm-up.
- Commit: bump the group epoch, register the new version, and let the router resume traffic.
- Health gates (error rate, p99 latency, quality probes) must pass before the next wave starts. The router only sends a request to groups whose committed epoch matches its routing policy.
5. Failure handling
- Stragglers: tracker watches per-peer throughput and re-sources chunks elsewhere; hedge requests near the tail. At the deadline, proceed if at least about 98% of groups are staged. Laggards stay out of rotation and catch up later.
- Mid-transfer dropouts: children re-parent to another rack seeder or the cache tier. Partial chunks are discarded; content addressing makes resumption idempotent.
- Corrupt chunks: drop on hash mismatch, refetch from a different peer, quarantine peers that repeatedly serve bad data.
- Rollback: keep the old version on NVMe (and in RAM if space allows). Rollback is the same 2PC in reverse plus a router weight flip, about a minute per wave. Triggers: failed canary, regressed health gates, too many stragglers. It should be automatic.
6. Trade-offs and common mistakes
- Pinned RAM staging makes the swap fast but consumes host memory that might otherwise serve KV-cache offload or other jobs; size it explicitly.
- Wave size trades rollout speed against capacity headroom and blast radius.
- Tracker centralization: a rack-local tracker limits blast radius; a global one is simpler but a bigger failure domain.
- Cap deploy traffic with QoS so rollouts do not starve live serving traffic.
- Common mistakes: ignoring oversubscription and treating the network as flat; forwarding unverified chunks; assuming both versions fit in VRAM; defining "atomic" per node rather than per model-parallel group; no automatic rollback criteria; claiming large delta savings for a full fine-tune.