cancel
Showing results for 
Search instead for 
Did you mean: 

Rootfs Size Increasing on Avenger96

Kaushendra
Associate II

Hi,

I'm using Avenger96 Board using Build-Sytem through Yocto.

I want to increase Rootfs Partition Size to 2Gb.

Changes done so far:

1)Edited /meta-st/meta-st-stm32mp/conf/machine/include/st-machine-common-stm32mp.inc

--ROOTFS_PARTITION_SIZE = "2097152"
--IMAGE_ROOTFS_MAXSIZE ?= "2097152"

I built the image,then while making "flashlayout_av96 weston_FlashLayout_sdcard_stm32mp157a-av96-trusted.raw" file

using the script "./scripts/create_sdcard_from_flashlayout.sh"

I'm facing Space Issue ,logs shown below

root@VM147:stm32mp1-av96# ./scripts/create_sdcard_from_flashlayout.sh flashlayout_av96-weston/FlashLayout_sdcard_stm32mp157a-av96-trusted.tsv
 
[WARNING]: A previous raw image are present on this directory
[WARNING]:    flashlayout_av96-weston/../flashlayout_av96-weston_FlashLayout_sdcard_stm32mp157a-av96-trusted.raw
[WARNING]: would you like to erase it: [Y/n]
y
Create Raw empty image: flashlayout_av96-weston/../flashlayout_av96-weston_FlashLayout_sdcard_stm32mp157a-av96-trusted.raw of 1536MB
Create partition table:
[CREATED] part 1:    fsbl1 [partition size 256.0 KiB]
[CREATED] part 2:    fsbl2 [partition size 256.0 KiB]
[CREATED] part 3:     ssbl [partition size 1024.0 KiB]
[CREATED] part 4:   bootfs [partition size 64.0 MiB]
[CREATED] part 5: vendorfs [partition size 16.0 MiB]
[WARNING]: IMAGE TOO BIG [rootfs:av96-weston-openstlinux-weston-stm32mp1-av96.ext4 2140129280 B [requested 786874368 B]
[WARNING]: try to move last partition
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
[ERROR]: IMAGE TOO BIG [rootfs:av96-weston-openstlinux-weston-stm32mp1-av96.ext4 2040 MB [requested 786874368 B]
[ERROR]: IMAGE + OFFSET of rootfs partition are superior of SDCARD size (1536)
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

Please let me know ,if i need further modifications or somethings i'm missing at my end

Thanks,

kaushendra

4 REPLIES 4
Christophe Guibout
ST Employee

Hello @Kaushendra​ ,

If you change rootfs size, I would recommand to update create_sdcard_from_flashlayout.sh script accordingly:

DEFAULT_RAW_SIZE=4096
DEFAULT_ROOTFS_PARTITION_SIZE=2097152

DEFAULT_RAW_SIZE is the size of your SDcard.

BR,

Christophe

Hi @Christophe Guibout​ 

Thanks for the Response.

I'll Implement as per your suggestion.

For future prospect i would like to know the Logic Implemented behind "Process of change in ROOTFS_PARTITION_SIZE and Corresponding change in create_sdcard_from_flashlayout.sh script accordingly"

Hence it will help me Develop Custom size in Future as per my requirement.

Regs,

kaushendra

OlivierK
ST Employee

Hi @Kaushendra (Community Member)​

The script parses the TSV file which has the original offsets of each partition. Computes the rootfs offset+size and warns if the overall size exceeds the size of the SDcard.

Here the rootfs size has been clamped to 768MB. It needs to be changed in the script to 2GB in your case ( DEFAULT_ROOTFS_PARTITION_SIZE=2097152).

Unfortunately, these values needs to be manually changed at the top of the script, should you modify the rootfs size again.

Best Regards

Olivier

Kaushendra
Associate II

Hi @OlivierK​ 

Thanks for the support.

Your Information is useful to me.

Regards,

kaushendra