, ,

How to plan storage for AI training and inference

A training checkpoint is about 14 bytes per parameter, nearly 1 TB for a 70B model, and large jobs crash every day or two. How big checkpoints are, how often to save them, which storage keeps up and how fast models load for inference. With a live calculator.

How to plan storage for AI training: a 140 GB model file next to a 980 GB checkpoint, and the best-interval curve

AI infrastructure · Kubernetes · Storage · Checkpoints · Model loading

GPUs get the attention, but storage quietly decides how much of their time is wasted. Training jobs save huge checkpoints and crash more often than anyone expects. Inference replicas have to load the model before they can answer anyone. This post works out how big a checkpoint is, how often to save it, which storage keeps up, and how long a model takes to load. The live calculator does the maths for your own model and cluster.

Try it: GPU Checkpoint Lab

Pick a model, a cluster size and a storage system. See the checkpoint size, how long each save stops the GPUs, the best save interval, and how long the model takes to load for inference.

Open the calculator →

The sizeA checkpoint is much bigger than the model

The model you download is just its weights: 2 bytes per parameter at 16-bit. A training checkpoint also holds everything needed to resume exactly where you stopped. With the common mixed-precision setup and the Adam optimizer, that is about 14 bytes per parameter:

2
4
4
4
16-bit weights
32-bit master copy of the weights
Adam first moment
Adam second moment
Total: 14 bytes per parameter, seven times the size of the model file. Some frameworks add a little more for scheduler and data-loader state.
8B model112 GBper checkpoint
70B model980 GBper checkpoint
405B model5.7 TBper checkpoint

The reasonLarge training jobs crash, a lot

419

Unexpected interruptions in 54 days while Meta trained Llama 3 on up to 16,000 H100 GPUs, about eight a day. Roughly 78% were hardware. Scaled down, a 1,024-GPU job can expect a crash about every two days.

Every crash throws away the work done since the last checkpoint, plus the time to restart and reload. So you want to save often. But while a checkpoint is being written, a simple training loop stops and waits, and every GPU in the job sits idle. So you also want to save rarely.

The best interval sits in the middle

0%5%10%15% save oftensave rarely best interval time spent saving work lost in crashes total waste

A handy rule (Young’s formula): best interval ≈ √(2 × time per save × time between crashes). Slow storage means a long save, which pushes the interval out and makes every crash more expensive.

The storageFour places to put checkpoints

From the calculator: a 70B model on 1,024 GPUs, saving every hour. Each card shows how long one save takes and how much GPU time is wasted in total.

NFS filer~2 GB/s

One shared NAS. Simple and familiar, but a 1 TB checkpoint takes over 8 minutes while 1,024 GPUs wait.

8.2 minper save
15.2%GPU time wasted
Object storage~10 GB/s

Cheap and huge. Good throughput with many parallel writers, slower for a single reader.

1.6 minper save
4.1%GPU time wasted
Parallel file system~80 GB/s

Lustre, Weka, IBM Storage Scale and similar. Built for thousands of clients writing at once.

12 sper save
1.7%GPU time wasted
Local NVMe, then copy~6 GB/s per node

Each node writes its own share to local disks, then uploads to object storage in the background. Fast, but lost if the node dies before the upload.

1 sper save
1.4%GPU time wasted
The cheap fix: save asynchronously. Copy the checkpoint to CPU memory, let training carry on, and write to storage in the background. PyTorch’s distributed checkpoint has an async_save for this. In the calculator, the same NFS filer drops from 15.2% to 2.2% waste.

InferenceHow long a model takes to load

For inference only the 16-bit weights are needed: 140 GB for a 70B model. A single node cannot use a whole storage system’s bandwidth, so load times depend on what one node can read:

NFS filer
1.2 min
Object storage
47 s
Local NVMe cache
23 s
Parallel file system
7 s

This is the “load weights” part of the cold start from the autoscaling post. Keeping a copy of popular models on each GPU node’s local disk is usually the simplest big win.

On KubernetesPutting it together

  1. Shared storage for checkpoints

    Training pods on different nodes write to one place, so you need a ReadWriteMany volume from a CSI driver for your parallel file system or NFS, or the object storage SDK directly.

    apiVersion: v1
    kind: PersistentVolumeClaim
    metadata:
      name: checkpoints
      namespace: research
    spec:
      accessModes: ["ReadWriteMany"]
      storageClassName: parallel-fs        # from your storage vendor's CSI driver
      resources:
        requests:
          storage: 50Ti
  2. Local NVMe for speed

    Expose each node’s NVMe disks as local volumes, for example with a local volume provisioner, and use them for the fast first write and for model caches.

  3. A model cache on every GPU node

    Download popular models once per node instead of once per pod, and mount the cache read-only into inference pods. An init container can fill it the first time.

  4. Keep only what you need

    A 70B job saving every hour writes almost 24 TB a day. Keep the last few checkpoints plus milestones, and delete the rest automatically.

Before you call it done
  • You know your checkpoint size and how long one save takes on your storage.
  • The save interval is based on your crash rate, not a round number.
  • Training saves asynchronously, or storage is fast enough that it does not matter.
  • You have tested restoring from a checkpoint, not just writing one.
  • Old checkpoints are cleaned up automatically.
  • Inference nodes keep a local cache of the models they serve.
Find your best interval

Open GPU Checkpoint Lab, pick your model and cluster size, and drag the interval until you find the lowest point on the curve.

Open the calculator →

Failure numbers are from Meta’s paper “The Llama 3 Herd of Models” (2024). Storage speeds are typical figures, not measurements of any product. The series so far: monitoring, logging, node lifecycle, sharing, scheduling, cost, autoscaling, networking and this post on storage. Next: GPUs on VMware Cloud Foundation.

About The Author


Discover more from Journal of Intelligent Infrastructure

Subscribe to get the latest posts sent to your email.

Leave a Reply

Your email address will not be published. Required fields are marked *

Architect’s Toolkit

About the Author

Dr. Pranay Jha is a Cloud and AI Consultant with 18+ years of experience in hybrid cloud, virtualization, and enterprise infrastructure transformation. He specializes in VMware technologies, multi-cloud strategy, and Generative AI solutions. He holds a PhD in Computer Applications with research focused on Cloud and AI, has published multiple research papers, and has been a VMware vExpert since 2016 and a VMUG Community Leader.

Discover more from Journal of Intelligent Infrastructure

Subscribe now to keep reading and get access to the full archive.

Continue reading