Last Minute Notes
  • Github
  • Docs
  • Learn
    @sayanstwt
Lessons
0/37 done
  • How a Request Travels
  • Back-of-Envelope Math
  • Latency & Percentiles
  • From One Server to Many
  • Availability & the Nines
Learn/System Design/Foundations

From One Server to Many

8 min Beginner 9 steps

Grow a system stage by stage, adding each piece only when it is needed.

Stage
1 of 8
Adds
nothing yet
Next trigger
CPU fight
UsersOne serverapp + DBCPU 40%scale up first: a bigger box is the simplest fix
request response data
In this lessonStep 1 of 9
  1. One box
  2. Split DB
  3. Scale out
  4. Cache + CDN
  5. Replicas
  6. Queues
  7. Shard
  8. Regions
  9. Recap
Step 1 / 9problem

Stage 1: everything on one server

Every system starts as one box running the app and the database. Scaling up (a bigger machine) is the simplest first fix.

Eventually the app and database fight over the same CPU and memory.

Key idea

Scale up first, until it hurts. A modern server handles far more than people assume.

←→ step·R replay·Space pause

You'll learn

  • Scale up before scaling out
  • Make app servers stateless so a balancer can spread load
  • Use cache, CDN and read replicas for read-heavy load
  • Move slow work to queues and shard only when forced
  • Name the trigger that moves you to each stage
Read the full notesSystem Design Fundamentals, 5