Thread (8 messages) 8 messages, 4 authors, 2012-10-28

Re: How does btrfs behave on checksum mismatch?

From: Michael Kjörling <hidden>
Date: 2012-10-27 22:10:04

On 27 Oct 2012 23:02 +0100, from hugo@carfax.org.uk (Hugo Mills):
quoted
I came across the tidbit that ZFS has a contract guarantee that the
data read back will either be correct (the checksum computed over the
data read from the disk matches the checksum stored on disk), or you
get an I/O error. Obviously, this greatly reduces the probability that
the data is invalid. (Particularly when taken in combination with the
disk firmware's own ECC and checksumming.)

With the default options, does btrfs make any similar guarantees? If
not, then are there any options to force it to make such guarantees?
   It does indeed do the same thing: if the checksum doesn't match the
block, then the alternative block is read (if one exists, e.g. RAID-1,
RAID-10). If that does not exist, or also has a checksum failure, then
EIO is returned.
Great!

This should perhaps be mentioned more clearly in the Wiki.

Also, thanks for the prompt reply.

-- 
Michael Kjörling • http://michael.kjorling.se • michael@kjorling.se
                “People who think they know everything really annoy
                those of us who know we don’t.” (Bjarne Stroustrup)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help