Hi all, While continuing my assessment of the online fsck code, I observed various other minor problems in the online scrub code. The most serious of the bugs involves the extent reference count checker, which incorrectly counts the number of rmaps it loads into the shared-extent record stack, and results in scrub being unable to detect off-by-one errors in the reference count. The three patches after that tighten the checking around the mininum number of records in a btree block; flags for rmap records; and validating that a null entry in the leaf bestfree block actually correspond to a hole in the directory data segment. If you're going to start using this mess, you probably ought to just pull from my git trees, which are linked below. This is an extraordinary way to destroy everything. Enjoy! Comments and questions are, as always, welcome. --D kernel git tree: https://git.kernel.org/cgit/linux/kernel/git/djwong/xfs-linux.git/log/?h=scrub-fixes-5.10 --- fs/xfs/scrub/bmap.c | 8 ++++---- fs/xfs/scrub/btree.c | 45 +++++++++++++++++++++++++++------------------ fs/xfs/scrub/dir.c | 27 ++++++++++++++++++++------- fs/xfs/scrub/refcount.c | 8 +++----- 4 files changed, 54 insertions(+), 34 deletions(-)