Greetings everyone.
I have been trying to expand root filesystem in iMX8MP-LPDDR4-EVK. I built a image with Yocto and it has root partition of around 7 GB. Flashing this image into eMMC leaves nearly 23GB of unused space. So, I tried expanding online with parted and resize2fs tools. The partition expands successfully but I encountered problems when trying to expand the rootfs.
So, I went through some similar topics and found this post. In one of the comments, u-boot was mentioned to be a way to resize partition. But I could not find any articles. I am looking for some guidance on how to expand rootfs through u-boot.
So far, I tried implementing the file system expansion mechanism used in Raspberry Pi. I was skeptic about the result and as expected, it did not work.
Please let me know if any further information are required.
@Bio_TICFSL Thank you for the reference.
I tried the method and got following errors.
After expanding the partition (I expanded just a little as test) , I could not run the command
e2fsck -f /dev/mmcblk2p2
The tool complains about the partition being mounted.
Despite this, I tried expanding the rootfs using
resize2fs /dev/mmcblkp2
I got a message stating "There are errors in the filesystem, so online resizing is not allowed."
I have attached the error screenshot.
I have encountered this error previously as well. So I though it would be a good idea to resize the partition and rootfs through U-Boot.
Thank you!!
Hello,
Please check this thread:
https://community.nxp.com/t5/i-MX-Processors/Resize-rootfs-of-Yocto-image/td-p/1426528
Regards