On 19/3/25 19:09, Johannes Thumshirn wrote:
From: Johannes Thumshirn <johannes.thumshirn@xxxxxxx> Recently we had a bug report about a kernel crash that happened when the user was converting a filesystem to use RAID1 for metadata, but for some reason the device's write pointers got out of sync. Test this scenario by manually injecting de-synchronized write pointer positions and then running conversion to a metadata RAID1 filesystem. In the testcase also repair the broken filesystem and check if both system and metadata block groups are back to the default 'DUP' profile afterwards. Link: https://lore.kernel.org/linux-btrfs/CAB_b4sBhDe3tscz=duVyhc9hNE+gu=B8CrgLO152uMyanR8BEA@xxxxxxxxxxxxxx/ Signed-off-by: Johannes Thumshirn <johannes.thumshirn@xxxxxxx> Reviewed-by: Filipe Manana <fdmanana@xxxxxxxx> --- Changes to v3: - Limit number of dirtied zones to 64 Changes to v2: - Filter SCRATCH_MNT in golden output Changes to v1: - Add test description - Don't redirect stderr to $seqres.full - Use xfs_io instead of dd - Use $SCRATCH_MNT instead of hardcoded mount path - Check that 1st balance command actually fails as it's supposed to
Much cleaner. Thx. Reviewed-by: Anand Jain <anand.jain@xxxxxxxxxx> Updated. Thx.