Set the autofsck property so that xfs_healer actually runs on
filesystems with old feature sets. Since these tests are looking for
error reports that don't require backref metadata (media errors, file IO
errors, shutdowns) we needn't _notrun them.
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Zorro Lang <zlang@kernel.org>
_require_scratch
_require_scrub
_require_command "$XFS_HEALER_PROG" "xfs_healer"
+_require_command "$XFS_PROPERTY_PROG" "xfs_property"
_require_dm_target error
_require_no_xfs_always_cow # no out of place writes
#
_scratch_mount
_require_xfs_scratch_non_zoned
+# Force xfs_healer to run even if there's no backref metadata
+$XFS_PROPERTY_PROG $SCRATCH_MNT set autofsck=check >> $seqres.full
_require_xfs_healer $SCRATCH_MNT
_scratch_unmount
_require_scrub
_require_dm_target error
_require_command "$XFS_HEALER_PROG" "xfs_healer"
+_require_command "$XFS_PROPERTY_PROG" "xfs_property"
_require_xfs_io_command verifymedia
filter_healer() {
_scratch_mount
_require_xfs_scratch_non_zoned
_require_xfs_healer $SCRATCH_MNT
+# Force xfs_healer to run even if there's no backref metadata
+$XFS_PROPERTY_PROG $SCRATCH_MNT set autofsck=check >> $seqres.full
_scratch_unmount
_dmerror_init
_require_scratch_nocheck
_require_scrub
_require_command "$XFS_HEALER_PROG" "xfs_healer"
+_require_command "$XFS_PROPERTY_PROG" "xfs_property"
_scratch_mkfs >> $seqres.full
_scratch_mount
_require_xfs_healer $SCRATCH_MNT
+# Force xfs_healer to run even if there's no backref metadata
+$XFS_PROPERTY_PROG $SCRATCH_MNT set autofsck=check >> $seqres.full
+
$XFS_IO_PROG -f -c "pwrite -S 0x58 0 500k" -c "fsync" $victim >> $seqres.full
echo "Start healer and shut down"