Skip to content

Case study: File sync & storage (Dropbox)

Design a cloud file sync service: content-addressed chunking, SHA-256 deduplication, write-blocks-before-commit metadata ordering, and conflict copies.

35 min9 steps

By the end you can
  • Estimate block ingress bandwidth, deduplication savings, metadata QPS, and long-poll client connections
  • Explain fixed vs Rabin content-defined chunking and why blocks are addressed by their SHA-256 hash
  • Separate immutable block storage from ACID versioned metadata and enforce write-blocks-before-commit
  • Predict how the system handles shared-folder hotspots, metadata DB failovers, and offline edit conflicts

Pin down what you are building

Features

  • Delta sync, dedup, version history, offline conflict copies

Targets

  • 1 KB-50+ GB files; propagate within seconds

Safety

  • 11-nines block durability; end-to-end checksums; no silent overwrite

A user modifies 50 KB inside a 400 MB video project and hits Save. How does Dropbox avoid uploading 400 MB?

Answer this step to continue.

What this lesson simplifies

  • The runnable cell simulates 2,000 requests/s over 15,000 files and content-addressed blocks.
  • Rabin rolling-hash chunk boundary detection happens on the client before calling the simulated commit endpoint.
  • Reed-Solomon erasure coding across storage racks is covered in the deep dive.

Sources

  1. J. Cowling (Dropbox Engineering). Inside the Magic Pocket: How Dropbox Built Its Exabyte Storage System, 2016.
  2. A. Muthitacharoen, B. Chen, D. Mazières. A Low-Bandwidth Network File System (LBFS), 2001.

Reviewed by Content lead on . Revision 1.