Re: ReiserFS / 2.4.6 / Data Corruption

From: Chris Wedgwood (
Date: Tue Jul 31 2001 - 18:45:13 EST

On Tue, Jul 31, 2001 at 03:32:39PM -0700, Dan Hollis wrote:

    How about an idea I proposed a while back, 'integrity loopback'?

    A loopback device which writes a CRC with each block and checks
    the CRC when read back.

    So if you have a flaky DMA controller, bad cables, etc you will
    know instantly. It would at least help catch the 'silent
    corruption' cases.

It still doesn't help with block-reordering, the fs needs some way to
communication write-barriers or relative block write ordering to the

To implement the device, I would hack loopback to take no only the
loopback file, but also another 'checksum' file of 160-bits or
whatever for each 4096 (or whatever) block. This file might initially
be of zero-length, in which case the bind is responsible for
checksumming the blocks and writing the checksums out on attach.

I say 160-bits (or whatever) so you can use something like SHA1 for
the checksums, this way you can use a small application to resync the
entire fs at the block level over a network without having to read
every block (ie. you compared checksums and then xmit the blocks).
The latter is something I needed a while ago.

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Tue Jul 31 2001 - 21:00:55 EST