A Dialogue on Persistence

Part III πŸ’¬ Dialogue OSTEP pp. 417–418 Β· ~3 min read

The third pillar begins the way the others did β€” with the professor, the student, and (the student insists) a peach.

Professor:And thus we reach the third of our four… err… three pillars of operating systems: persistence .
Student:Did you say three pillars, or four? What’s the fourth?
Professor:No. Just three, young student, just three. Trying to keep it simple here.
Student:OK, fine. But what is persistence, oh fine and noble professor?
Professor:You know it in the traditional sense already β€” as the dictionary says: β€œa firm or obstinate continuance in a course of action in spite of difficulty or opposition.”
Student:Kind of like taking your class: some obstinance required.
Professor:Ha! Yes. But here it means something else. Imagine you’re in a field, and you pick a β€”
Student:(interrupting) I know! A peach! From a peach tree!
Professor:I was going to say an apple. Oh well; we’ll do it your way. You pick many peaches, and you want them to last a long time β€” winter is hard and cruel in Wisconsin. What do you do?
Student:Lots of things! Pickle it, bake a pie, make jam. Fun!
Professor:Fun? Maybe. But certainly a lot more work to make the peach persist. And so it is with information: making it persist β€” despite computer crashes, disk failures, and power outages β€” is a tough and interesting challenge.

The peach, and the point: raw things perish; preserved things persist β€” and the same is true of your data.

the peachπŸ‘fresh β†’ rots by winterπŸ«™πŸ₯§jam / pie / picklepreserved β†’ lastsextra work buys survivalβ†’your datain memory onlycrash / power loss β†’ goneon disk / FS πŸ’Ύpersists across crashesI/O devices, disks, file systems, journaling β€” the work of Part III
Student:Nice segue; you’re getting quite good at that.
Professor:Thanks! A professor can always use a few kind words.
Student:I’ll try to remember that. Time to stop talking peaches and start talking computers?
Professor:Yes, it is that time…

The road through Part III

Persistence is a whole stack, and we’ll climb it from the metal up:

I/O devicesch36β€ΊHDD Β· SSDch37Β·44β€ΊRAIDch38β€ΊFile systemsch39–41β€ΊJournaling Β· LFSch42–43β€ΊData integritych45β€ΊDistributed FSch47–50from the raw device up to file systems that survive crashes and span networks

Check yourself: what persistence means

1.In the systems sense, what does persistence mean?

2.How does preserving a peach (jam, pie, pickle) map to the systems idea?

3.Why is achieving persistence a genuinely hard challenge (not just 'write the data down')?

4.Persistence is which of the OS's pillars, and how many are there in this book?

4 questions