I am on a test VM where I am trying to convert a second disk to btrfs.
The conversion fails with the error missing data block for bytenr 1048576
(see below).
I couldn't find any information about the error. What can I do to fix this?
$ fsck -f /dev/sdb1
fsck from util-linux 2.35.2
e2fsck 1.45.6 (20-Mar-2020)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/sdb1: 150510/4194304 files (0.5% non-contiguous), 2726652/16777216 blocks
$ btrfs-convert /dev/sdb1
create btrfs filesystem:
blocksize: 4096
nodesize: 16384
features: extref, skinny-metadata (default)
checksum: crc32c
creating ext2 image file
ERROR: missing data block for bytenr 1048576
ERROR: failed to create ext2_saved/image: -2
WARNING: an error occurred during conversion, filesystem is partially created but not finalized and not mountable
Best Answer
It was a bug
Also see:
As a workaround you can resize your filesystem to something smaller/larger before the conversion.