[OE-core] Contents of non-rootfs partitions

Kristian Amlie kristian.amlie at mender.io
Tue Nov 22 09:54:47 UTC 2016


On 22/11/16 10:27, Yann Dirson wrote:
> Since usually such a data partition needs to be written at times, you'll anyway have to handle the event of it getting corrupted, and possibly have to reformat it.
> With this in mind, one option is to include default contents in your rootfs, and populate the persistent one on first boot.

That's true, and a neat solution, but I consider this somewhat orthogonal. It solves the problem at run time, whereas my proposal tries to solve it at build time. With your solution, in a dual rootfs layout situation, you're paying the space cost of the initial data partition contents three times over, once in each of the two rootfs filesystems and once in the data filesystem. Depending on whether you have logic to detect a corrupt data partition or not, this price may not be worth paying if you can have a prepopulated data partition.

It also has higher complexity, particularly integrating the population step in the boot sequence. I'm not opposed to this solution, but maybe it makes sense to start smaller?

-- 
Kristian



More information about the Openembedded-core mailing list