BTRFS-Errors - How to fix?

According to the btrfs documentation:

The device stats keep persistent record of several error classes related to doing IO. The current values are printed at mount time and updated during filesystem lifetime or from a scrub run.

corruption_errs
A block checksum mismatched or a corrupted metadata header was found.

-z|--reset
Print the stats and reset the values to zero afterwards.

If the reported stats are no longer needed because the errors are fixed (maybe you can run btrfs check or whatever is needed to recheck blocks and metadata headers):

btrfs device stats --reset /dev/sda1
3 Likes