Segment Cleaning
How to identify file that a block belongs to?
How to identify live blocks?
LFS solution: segment summary block
- maps data blocks to file-id+block-id
- version number: identifies live blocks
- updated on overwrite or delete
- version number + inode number = uid
Notes:
to check whether a block is live or not:
look into file’s inode or indirect block and see if this block is in it.
FFS: free block list or bitmap.
Saves disk space and memory