[yocto] partitions resizing on the fly

Mihaela Apetroaie-Cristea apetroaiecristeamihaela at gmail.com
Tue Jun 5 07:59:14 PDT 2018


Hi, 

Thanks for your answer. However, my question is whether there is a mechanism such that the root will keep it’s minimal size, but be able to expand if there is free space on the disk when new files are added (not necessarily to occupy the whole free space), and shrink back if files are deleted. At the moment I am happy to flash it with the minimal size, but it runs out of space when I want to add something to the partitions, although there is extra space on the disk that it could take. I know the implementation of this is complicated, but I am wondering if anyone knows a solution for this.

Thank you

> On 5 Jun 2018, at 15:50, Iván Castell <icastell at nayarsystems.com> wrote:
> 
> I managed this issue redefining this script in my custom layer (rocko branch):
> 
>     scripts/lib/wic/canned-wks/mkefidisk.wks
> 
> and setting a bigger size for the root partition (80GB in my case):
> 
>     part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid --size 80000
> 
> Its not very nice, I know. But yocto can't know the real size of your root device until writing the final image.
> 
> I don't know if this is the best way to fix this  but it works. 
>   -- Ivan
> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20180605/dbf24c70/attachment.html>


More information about the yocto mailing list