On 2016-11-25 05:31, Zygo Blaxell wrote: >>> Do you mean, read the corrupted data won't repair it? >>> >>> IIRC that's the designed behavior. >> :O >> >> You are right... I was unaware of that.... > This is correct. > > Ordinary reads shouldn't touch corrupt data, they should only read > around it. Scrubs in read-write mode should write corrected data over > the corrupt data. Read-only scrubs can only report errors without > correcting them. > > Rewriting corrupt data outside of scrub (i.e. on every read) is a > bad idea. Consider what happens if a RAM controller gets too hot: > checksums start failing randomly, but the data on disk is still OK. > If we tried to fix the bad data on every read, we'd probably just trash > the filesystem in some cases. I cant agree. If the filesystem is mounted read-only this behavior may be correct; bur in others cases I don't see any reason to not correct wrong data even in the read case. If your ram is unreliable you have big problem anyway. The likelihood that the data contained in a disk is "corrupted" is higher than the likelihood that the RAM is bad. BTW Btrfs in RAID1 mode corrects the data even in the read case. So I am still convinced that is the RAID5/6 behavior "strange". BR G.Baroncelli -- gpg @keyserver.linux.it: Goffredo Baroncelli <kreijackATinwind.it> Key fingerprint BBF5 1610 0B64 DAC6 5F7D 17B2 0EDA 9B37 8B82 E0B5 -- 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
