LightMySky
En anglais

Failure Models and Replication

A distributed system has to say what kinds of failure it tolerates: a machine that stops, a message that never arrives, a machine that stops and comes back with old state. Replication is the usual answer, and it turns one copy's truth into a question about which copy to believe.

Commence ce sujetPas besoin de compte. La progression est enregistrée dans ce navigateur.

Ce que l'enfant saura faire ensuite

  • Explain why a crashed node and a slow one look the same from outside, and why that is hard to resolve
  • Explain what a primary and its replicas each promise a client
  • Say what a replica that rejoins with stale state has to do before serving reads

1 · Lis

You already know messages carry order between machines. Now ask what can go wrong. A machine can stop dead, a message can vanish, or a stopped machine can return later still believing old state. First you must name which failure you tolerate.

Try it together

You call a node and hear nothing. It may have crashed, or it may just be slow. From outside both look identical: silence. Systems set a timeout so they can act after a wait, but a timeout still cannot tell the two apart for sure.

Replication is the usual answer: keep copies on several machines. The primary takes writes and promises one order, while replicas copy it and promise to serve only what they have caught up with. One copy's truth becomes a question about which copy to believe.

A replica that rejoins with stale state must catch up before serving reads. It copies the changes it missed first, and only then answers clients. Otherwise it hands out yesterday's truth.

primary orders w1 w2 w3replica holds w1 w2serves only w1 w2copies w3, then serves it
A replica serves only what it has copied, in the primary's order, then catches up.

Name the failures you tolerate, remember silence hides crash and slowness alike, and never let a stale replica answer.

Original instructional content authored for os-taxonomy.

2 · Regarde

En anglais

Sans écran

Imprimer une fiche d'exercicesFormat A4, avec une page de corrigés pour les adultes. Sans écran, sans internet.

Où se situe ce sujet

Puis s'entraîner

8 questions attendent derrière cette leçon, chacune avec sa réponse expliquée. Chaque réponse nourrit le ciel : les étoiles s'allument à mesure qu'elles sont apprises, et pâlissent quand vient le moment de revenir.

Commence ce sujet