Expanding rootfs from uboot.

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Expanding rootfs from uboot.

1,719件の閲覧回数
bgaurav1718
Contributor III

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. 

タグ(3)
0 件の賞賛
返信
2 返答(返信)

1,686件の閲覧回数
bgaurav1718
Contributor III

@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!!

0 件の賞賛
返信

1,697件の閲覧回数
Bio_TICFSL
NXP TechSupport
NXP TechSupport
0 件の賞賛
返信