File System Implementation Flashcards
Problems with Linked Allocation of blocks?
Direct access is slow. Breaking one block potentially loses rest of file.
Problems with contiguous allocation?
External Fragmentation. Need to shift entire file every time new blocks are needed.
What is a FAT table?
File Allocation Table. Linked list allocation, but the pointers are stored in a table, rather than the blocks themselves.
A lot faster for direct access. Multiple tables are needed as table grows.
What is a FAT table?
File Allocation Table. Linked list allocation, but the pointers are stored in a table, rather than the blocks themselves.
A lot faster for direct access. Multiple tables are needed as table grows.
What is the difference between a journaling, and version file system?
Journaling only keeps track of the changes made to files, while versioning maintains a history of changes for each file.
What are the different ways to implement a versioning file system?
1) Copy every file
2) Log- Track the changes made to files, while only keeping the latest one.
3) Tree - Break the file down into a tree, which is traversed everytime a file is needed
Why version files?
1) Recover from mistakes
2) Restore damaged files
3) Implement security (revert to a version before breach)
When should a new version file be created?
Either with every write to the file, or only when the file is closed.
Characteristics of a log version system
1) Compact
2) Quick to access latest version
3) Need to go through and make all the changes in the log in sequential order (can be slow if many versions)
4) Can be solved with checkpoint files.
Characteristics of a tree version system
1) Accessing any version takes the same amount of time.
2) This can be too slow if tree gets really big
3) Easy to revert to an older version
In which aspect are log and tree versioning systems bad?
If the data between versions is very different (in this case it probably better to just keep direct copies).