</> MAANG.io
system design Β· 201

Intermediate

Master system design interviews with scalable architecture patterns, distributed systems, and real-world design challenges.

0/124 solved 0% complete

Paxos

maang.io System Design Series


Paxos solves the hardest problem in distributed systems: getting unreliable machines to agree on one value, provably, even as messages are lost, delayed, or reordered. Its safety rests on one fact β€” any two majorities overlap β€” which forces every later proposer to honor an already-chosen value. Multi-Paxos extends it into the replicated log behind systems like Spanner and Chubby.

This deep dive comes in three parts:

  • Foundations & Core Concepts β€” the roles, the two-phase protocol, and why consensus is hard.
  • Internals β€” acceptor state, the safety proof, dueling proposers, and Multi-Paxos, with worked numbers.
  • Interview β€” Staff/Principal Q&A: safety vs liveness, quorum math, and Paxos vs Raft.

Paxos β€” Part 3: System Design & Interview Mastery

maang.io System Design Series


What is this?

You now know Paxos from the acceptor's two variables up to Multi-Paxos's replicated log. This chapter is where that pays off in a room. Interviewers almost never ask you to recite the protocol β€” they ask you to recognize when a design needs consensus, reach for it (or deliberately avoid it), and defend the cost when they push back. The senior signal isn't "I can describe Prepare and Accept." It's "I know that consensus is expensive, I use it only where a system genuinely needs one agreed truth, and I can tell you exactly what it buys and what it costs."

We'll do two things: see where Paxos fits in real designs (with diagrams), then run a mock interview β€” for each question, what they're really asking, a model answer, and the senior line that signals you've built this for real.

The one-line idea: interviewers use Paxos to test whether you can tell "we need everyone to agree on one thing" (consensus β€” Paxos/Raft) apart from "we need this to always be writable" (availability β€” quorum replication/gossip) apart from "we need these separate parties to commit together" (atomicity β€” 2PC). Naming which problem you're in is the whole game.

Our six friends and their dinner vote come along one last time β€” because "the group must agree on exactly one plan, and survive some phones dying" is precisely the shape that should make Paxos light up in your head.


Sign in to continue reading

The rest of this lesson is available with a free account. Signing in with Google or Microsoft is free.

Sign in to read the full lesson

Sign in to MAANG.io

Use your Google or Microsoft account β€” no password to remember.

Continue with Google Continue with Microsoft

Please accept the terms above to continue.