Re:Filesystems can experience at least three different sorts...
by cmurf on Saturday March 12, 2022 @06:13PM
(#30655953)
Actually, I have seen a write time tree checker error on one of my file systems. I even reported the bug :) So it also has the benefit of ratting out btrfs itself when it's the cause. The file system did go read only, corruption didn't make it to disk, and it was fine following a reboot (it was the root file system so I couldn't unmount then mount; and this kinds of confusion can't be cleared with a remount).
https://patchwork.kernel.org/project/linux-btrfs/patch/024e4...
https://www.man7.org/linux/man-pages/man8/btrfs-device.8.htm...
Man page includes definitions of the 5 kinds of errors tracked.
The article mentions structural errors. Sounds like this is the detection of an inconsistency. These aren't counted on btrfs, but are logged. Anytime the read or write time tree checker finds a problem, it results in the filesystem going read-only to prevent (further) confusion from ending up on disk. These are exceptionally rare, I've never seen one on any of my filesystems; but have seen it catch things like bitflips due to bad RAM, i.e. the checksum was computed correctly on already corrupted (meta)data.