Paxos consensus algorithm — concept page for /concepts/paxos. Visualizes proposer/acceptor/learner roles, two-phase prepare/accept protocol, majority quorum, Multi-Paxos optimization with stable leader, and the duelling-proposers livelock problem. 5 acceptors + 2 proposers + 2 learners. Five scenarios: basic-happy (single decree 2 RTT), conflict-prior-wins (safety preservation), livelock-duelling-proposers (with showError + flashError + Multi-Paxos fix), multi-paxos-stable-leader (1 RTT per slot), greek-mess-why-hard (Paxos Made Live war stories). Two ADRs: full algorithm description, and Paxos vs Raft comparison.
Single-decree Paxos chooses one value despite crash failures and message loss, duplication, delay, or reordering. A proposer first gathers promises for a unique ballot from a majority. It must propose the value attached to the highest previously accepted ballot in those replies, or its own value if none was accepted. A value becomes chosen only after a majority accepts it.
With 2f+1 acceptors, any majority has f+1 members and any two majorities intersect. Stable promises and accepted records carry the safety chain across crashes. One distinguished proposer improves liveness, but leader election is not the safety proof; dueling proposers can stall without choosing conflicting values.
prepare-promise-majority): A proposer obtains durable promises and must adopt the highest accepted value returned.accept-chosen-value): Two of three durable accepts form a chosen certificate; the third may be unavailable.competing-proposer): Higher ballots preempt lower ones; contention can stall but cannot choose two values.leader-failover-gap): A new Multi-Paxos leader recovers missing slots before applying a later chosen suffix.learner-recovery): Lost learner notifications do not unchoose a value; later proposal traffic reveals it.stable-storage-restart): An acceptor reloads its promise before serving; forgetting it would violate safety.Raft consensus is an explore diagram and is linked as Markdown.
Введите числа или выберите пресет