On Sep 14, 2012, at 12:27 PM, Robin Hill wrote: > On Fri Sep 14, 2012 at 12:04:56 -0600, Chris Murphy wrote: > >> >> On Sep 14, 2012, at 1:45 AM, Niccolò Belli wrote: >> >>> I also would like to know if the raid1 will *surely* use data from >>> the other disk to write on the broken sector after a CHECK. >> >> Not according to documentation. In normal operation, and for a repair, >> what you describe is correct. But not for check. >> > Maybe you need to reread the documentation. Probably. It's densely packed. > So a check will repair cases where the data cannot be read at all, but > will not repair cases where the data is returned but does not match the > data on the other mirror(s). Yes, I now see the distinction between disk read-error and an array block mismatch. > >>> I read that when raid1 is in doubt there is a 50%-50% chance it uses >>> data from the good disk, wouldn't be better to fail the broken disk >>> and then re-add it to the array? >> >> I don't know what this means. >> > I assume he's referring to cases where the data is read successfully but > does not match the data on the mirror(s). In this case a repair will > cause one copy to overwrite the others, which may or may not be the > correct copy (md has no way of knowing for a mirrored pair). I understand the ambiguity. It seems ill advised to arbitrarily replace what could be valid data. So some clarification on what repair does in a raid 1,10 block mismatch would be useful, as it may be repair shouldn't be used: rather use check and find out what file(s) are affected by the mismatch and replace the files from backup. This statement from documentation is confusing to me: "For RAID1/RAID10, all but one block are overwritten with the content of that one block." Chris Murphy-- To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html