Which file system automatically stores hashes of files?

12

1

Which file system automatically computes and stores hashes of files and later checks them at access to detect corruption?

Adrian Panasiuk

Posted 2009-08-03T19:56:29.500

Reputation: 885

Sounds like a homework question. Especially the way it's asked. – Travis – 2009-08-03T20:22:20.107

6during the summer vacations? – Adrian Panasiuk – 2009-08-03T20:34:33.307

1Good point! :-) But I could just imagine this question with a 5) in front of it on a printed piece of paper. – Travis – 2009-08-05T19:32:06.763

@AdrianPanasiuk Now wait for someone to come and say "Sounds like someone who failed exams and got homework for summer" :D – AnonymousLurker – 2012-08-05T18:37:21.483

Answers

15

Sun's ZFS does:

With ZFS, all data and metadata is checksummed using a user-selectable algorithm. Traditional file systems that do provide checksumming have performed it on a per-block basis, out of necessity due to the volume management layer and traditional file system design. The traditional design means that certain failure modes, such as writing a complete block to an incorrect location, can result in properly checksummed data that is actually incorrect. ZFS checksums are stored in a way such that these failure modes are detected and can be recovered from gracefully. All checksumming and data recovery is done at the file system layer, and is transparent to applications.

And so does Linux's btrfs: Btrfs also supports both data and metadata checksumming. Data checksumming is optional and can be disabled by mounting with -o nodatasum.

knweiss

Posted 2009-08-03T19:56:29.500

Reputation: 1 636

Further, if your filesystem is mirrored, I believe it can recover from the error. – Mechanical snail – 2011-10-15T23:16:33.957