btrfs/139: require 2GB scratch dev
authorJohannes Thumshirn <jth@kernel.org>
Fri, 3 Jan 2020 11:29:05 +0000 (12:29 +0100)
committerEryu Guan <guaneryu@gmail.com>
Mon, 6 Jan 2020 08:15:04 +0000 (16:15 +0800)
In my testing on 1GB zram devices btrfs/139 usually fails with
ENOSPC.

Add a requirement for 2GB scratch devices (empirically measured).

Signed-off-by: Johannes Thumshirn <jth@kernel.org>
Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
tests/btrfs/139

index 5664617..1b636e8 100755 (executable)
@@ -33,7 +33,8 @@ rm -f $seqres.full
 
 _supported_fs btrfs
 _supported_os Linux
-_require_scratch
+# We at least need 2GB of free space on $SCRATCH_DEV
+_require_scratch_size $((2 * 1024 * 1024))
 
 _scratch_mkfs > /dev/null 2>&1
 _scratch_mount