Sdimg creation error - Yocto Zeus i.MX 8M mini EVK

I got this error: ERROR: Actual rootfs size (29280 kB) is larger than allowed size 16384 kB while building mender image. The contents of wks file is given below.

I’ve tried changing MENDER_STORAGE_TOTAL_SIZE_MB to various large values, still I’m getting the same errors(ERROR: Actual rootfs size (29280 kB) is larger than allowed size 16384 kB).

### Contents of wks file ###
cat /home/ux/imx8/yocto/zeusl/core-base-build/tmp/work/imx8mmevk-poky-linux/core-image-base/1.0-r0/mender-sdimg.wks
# embed bootloader
part --source rawcopy --sourceparams="file=/home/ux/imx8/yocto/zeusl/core-base-build/tmp/work/imx8mmevk-poky-linux/core-image-base/1.0-r0/u-boot-imx8mmevk.bin-sd" --ondisk "mmcblk1" --align 33 --no-table
part --source rawcopy --sourceparams="file=/home/ux/imx8/yocto/zeusl/core-base-build/tmp/work/imx8mmevk-poky-linux/core-image-base/1.0-r0/uboot.env" --ondisk "mmcblk1" --align 8192 --no-table
part --source rootfs --rootfs-dir /home/ux/imx8/yocto/zeusl/core-base-build/tmp/work/imx8mmevk-poky-linux/core-image-base/1.0-r0/bootfs.image_sdimg --ondisk "mmcblk1" --fstype=vfat --label boot --align 8192 --fixed-size 16 --active
part --source rawcopy --sourceparams="file=/home/ux/imx8/yocto/zeusl/core-base-build/tmp/work/imx8mmevk-poky-linux/core-image-base/1.0-r0/deploy-core-image-base-image-complete/core-image-base-imx8mmevk.ext4" --ondisk "mmcblk1" --align 8192 --fixed-size 3031040k
part --source rawcopy --sourceparams="file=/home/ux/imx8/yocto/zeusl/core-base-build/tmp/work/imx8mmevk-poky-linux/core-image-base/1.0-r0/deploy-core-image-base-image-complete/core-image-base-imx8mmevk.ext4" --ondisk "mmcblk1" --align 8192 --fixed-size 3031040k
part --source rawcopy --sourceparams="file=/home/ux/imx8/yocto/zeusl/core-base-build/tmp/work/imx8mmevk-poky-linux/core-image-base/1.0-r0/deploy-core-image-base-image-complete/core-image-base-imx8mmevk.dataimg" --ondisk "mmcblk1" --align 8192 --fixed-size 32 --mkfs-extraopts=''

bootloader --ptable msdos
### End of contents of wks file ###

Can you help me getting it right?

How can I control the wks file to only include u-boot image in the FAT partition?

Are you certain that your changes of the MENDER_STORAGE_TOTAL_SIZE_MB are in effect? I’ve had issues occasionally where I was setting that variable in local.conf but it was also set elsewhere and my changes were ignored.

If you run “bitbake -e core-image-base” and save the output, it will show you the value of that variable and exactly how it was set, by which layers, conf files, etc

Drew

After further analysis, I found that the problem is caused by this line: part --source rootfs --rootfs-dir /home/ux/imx8/yocto/zeusl/core-base-build/tmp/work/imx8mmevk-poky-linux/core-image-base/1.0-r0/bootfs.image_sdimg --ondisk "mmcblk1" --fstype=vfat --label boot --align 8192 --fixed-size 16 --active

Here, it’s trying to copy whole directory to the 16MB FAT partition, where in the u-boot file is only required. Do you have any comments on this one?

Yes, if you look at the contents of wks file (on line 4 & 5) there are two partition of roughly 3GB as two root file systems. This indicates that the MENDER_STORAGE_TOTAL_SIZE_MB = "6000" took effect.

That directory is populated by the contents of the IMAGE_BOOT_FILES variable so you’ll need to trim that down.

Drew

danie
I have been struggling porting the iMX8evk to zeus also.
Seems mostly issues with boot loader.
How far did you get?

Yes, we too faced issues in mender U-boot integration in Zeus. So, we’ve ported back to sumo branch.

I also have the sumo branch working just fine. NXP has released the zeus BSP for iMX8 a few months back but mender support seems to be lagging. I see a few people working on dunfell but nothing on iMX8 yet.

Yes, Mender has general integration support for Zeus (I hope) and it’s up-to users for porting into specific board as it’s nearly impossible for mender to cover all the boards.
I’m working on that (Zeus branch) and update here if something turns fruitful. Thank you.