Closed elliott-beach closed 6 years ago
I'm assuming we can load the entire file system in memory for this. Counting the number of links to each file seems to require that.
@kstowe I'm slightly stumped by how to implement the last one, all blocks not mentioned in the inode are marked as free blocks. The tough part is traversing all possible block addresses.
Write
fsck.cc
, which checks a file system for internal consistency. It should verify thatYou may need to manually induce errors in your file system to test this.