Preparation for Recitation on LFS
Read Chapter 43 of "Operating Systems: Three Easy Pieces" by Remzi H. Arpaci-Dusseau and Andrea C. Arpaci-Dusseau. This chapter describes a log-structured file system.
The Log-Structured File System departs dramatically from the UNIX File System and proposes, instead, a file system in which all of the data is stored in an append-only log, that is, a flat file that can be modified only by having data added to the end of it. In Chapter 9, we also hear about logs, specifically how they help achieve reliability. For today's reading, the purpose of the log is to achieve good performance.
The primary goal of a log-structured file system is to minimize seeks by treating the disk as an infinite append-only log. For example, the file system software simply appends new files to the end of the log.
As you read, think about the following:
- The "infinite log" is actually on a finite disk; how does that constraint affect the designers' goals?
- Are there certain file access patterns by applications might make it hard for a log-structured file system to avoid seeks?
Question for Recitation
Before you come to this recitation, write up (on paper) a brief answer to the following (really—we don't need more than a couple sentences for each question). If your TA has requested that you email your answer to them, you may do that instead, but it should still be handed in before your recitation begins.
Your answers to these questions should be in your own words, not direct quotations from the paper.
- What is one technique that the log-structure filesystem uses to achieve higher performance? (There is more than one technique)
- How does the log-structured file system implement this technique?
- Why does this technique, along with minimizing seeks, lead to good performance?