With btrfs-prog 4.17 as shipped with Alpine 3.8 the btrfs tests
fail with:
ERROR: '/dev/loop1' is too small to make a usable filesystem
ERROR: minimum size for each btrfs device is 114294784
btrfs-prog commit 997f9977c243 ("btrfs-progs: mkfs: Prevent
temporary system chunk to use space in reserved 1M range")
changed the code to compute the minimum size for a btrfs size
and is the likely reason for this error.
Increase the size of the loop back device to 128MB for
the btrfs test.
With this fix, the containerd tests pass on Alpine 3.8,
tested in LinuxKit with kernel 4.14.53.
fixes#2447
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@gmail.com>
Use a smaller filesize on systems that have a default 4KB pagesize.
This is because mkfs.btrfs uses the default system pagesize as blocksize
when creating a device, so if the pagesize is larger, then the file needs
to be larger as well. This larger filesize is needed specifically for
systems where 64KB is default, such as ppc64le.
Signed-off-by: Christopher Jones <tophj@linux.vnet.ibm.com>
Cleans up loop devices if part of the test or mount process fails.
Also increases btrfs default file size to 650MB to accommodate
minimum btrfs size on ppc64le and s390x
Signed-off-by: Christopher Jones <tophj@linux.vnet.ibm.com>
Implements btrfs usage using a double walking diff and
counting the result. Walking gives the most accurate
count and includes inode usage.
Signed-off-by: Derek McGowan <derek@mcgstyle.net>