Re: Will BTRFS repair or restore data if corrupted?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> So if I for example edit a text file three times and store it I can get the
> following.
> Version1: I currently like cheese
> Version2: I currently like onions
> Version3: I currently like apples
> As far as I understand a disk corruption might result in me suddenly liking
> onions (or even cheese) instead of apples without any warning except in
> syslog.?! I really hope I have misunderstood the concept and that there is
> some error correction codes somewhere.

Yes, you've completely misunderstood the concept :p

There are crc's on each 4k block of data; if one copy fails the
checksum, and a second copy is available, and that copy does match,
then the good data will be returned and btrfs will overwrite the
corrupted copy with the good copy.  If there isn't another copy, then
an io error will be returned instead.
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux