Even though pmbootstrap reports otherwise, --image-size <whatever> doesn't actually do anything when running Qemu on a non-x86_64 architecture (in my testing, armhf).
If I manually resize the image using truncate +1G qemu-vexpress.img, pmbootstrap does however complain when not setting --image-size to the correct value.
ERROR: The system image size must be 3072M or greater
But when booting the image, the root partition doesn't get resized to use up all the new space.
The --image-size argument works as expected. The real issue is that the partition is not resized.
This is due the way we use to detect it, see here.
In the qemu-vexpress the root partition is /dev/mmcblk0p2, but if we change the resize function to detect that one, we will also start resizing the device partitions or the partitions in the actual sd-cards.
I see some possible solutions to force the partition resize:
deviceinfo_initfs_force_partition_resize="true")PMOS_FORCE_PARTITION_RESIZE)if devicename starts with qemu then resize@ollieparanoid what you think about it?
I would prefer the 2nd option, because we only need this in the initramfs and we do it the same way with the logging already.
Most helpful comment
The
--image-sizeargument works as expected. The real issue is that the partition is not resized.This is due the way we use to detect it, see here.
In the
qemu-vexpressthe root partition is/dev/mmcblk0p2, but if we change the resize function to detect that one, we will also start resizing the device partitions or the partitions in the actual sd-cards.I see some possible solutions to force the partition resize:
deviceinfo_initfs_force_partition_resize="true")PMOS_FORCE_PARTITION_RESIZE)if devicename starts with qemu then resize@ollieparanoid what you think about it?