Hi Chris,

On 04/06/2017 08:50 AM, Josef Holzmayr wrote:
Hi,

On 06.04.2017 08:41, Maier, Chris wrote:
Hi,

I want to create a deployable SD card image. My board (beaglebone
based) boots from SD card and runs a script which copies the
rootfs.tar.bz2 to the flash memory.

So how can I deploy a copy of the whole rootfs to ${D}/home/root?

A rootfs in the rootfs, does that make sense?

Partially. Sounds like you want to invent your own update mechanism.
Have you had a look at the already existing ones, specifically swupdate?

if you intend to build an update system, Josef is right, choose an existing (image/archive-based) one. Here is a good overview and comparison of update frameworks currently supported by meta layers:

  https://wiki.yoctoproject.org/wiki/System_Update

If you intend to do this for factory bootstrapping your device instead, i.e. you also set up the flash partitioning etc. this is partly out of the scope of these tools. A typical setup we use for this is a rootfs partition on your disk that you start your factory system from, and a second data partition where you place your rootfs in.

We use the `genimage` [1] tool for creating such images that also allows packing build images into a data partition, but this should be possible with Yocto's `wic` [2], too.

Note that you can also do a two-step approach where you set-up the flash storage with a script first and then already use an update tool to deploy the initial content (from the data partition) to it. Note that not all tools will support this by their configuration, currently.


Best regards, Enrico


[1] https://git.pengutronix.de/cgit/meta-ptx/tree/classes/genimage.bbclass
[2] http://www.yoctoproject.org/docs/latest/mega-manual/mega-manual.html#creating-partitioned-images

--
Pengutronix e.K.                           | Enrico Jörns                |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-5080 |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

--
_______________________________________________
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto

Reply via email to