On Tue, Jun 15, 2021 at 12:17 AM Brian Hutchinson <b.hutchman@gmail.com> wrote:
Hi Jan,

So using your manifest example and my partition scheme from earlier ...

RAUC A slots:
/dev/mmcblk2gp0p1 (kernel/dtb)
/dev/mmcblk2gp0p2 (rootfs)
/dev/mmcblk2p1 (appfs)

RAUC B slots:
/dev/mmcblk2gp1p1 (kernel/dtb)
/dev/mmcblk2gp1p2 (rootfs)
/dev/mmcblk2p2 (appfs)

On Tue, May 25, 2021 at 2:56 AM Jan Lübbe <jlu@pengutronix.de> wrote:

So your manifest might look like:
[update]
compatible=rauc-example
version=2021.05-1

[bundle]
format=verity

[image.kernel]
filename=kernel.img

[image.rootfs]
filename=rootfs.tar

[image.appfs]
filename=appfs.tar


Best regards,
Jan



My system.conf (using my example partition layout for earlier email) file would look something like:

[system]
compatible=rauc-example
bootloader=uboot

[keyring]
path=/etc/rauc/ca.cert.pem
 
[slot.kernel.0]
device=/dev/mmcblk2gp0p1
type=vfat
parent=rootfs.0

[slot.kernel.1]
device=/dev/mmcblk2gp1p1
type=vfat
parent=rootfs.1

[slot.rootfs.0]
device=/dev/mmcblk2gp0p2
type=ext4
bootname=A

[slot.rootfs.1]
device=/dev/mmcblk2gp1p2
type=ext4
bootname=B

[slot.appfs.0]
device=/dev/mmcblk2p1
type=ext4
parent=rootfs.0

[slot.appfs.1]
device=/dev/mmcblk2p2
type=ext4
parent=rootfs.1

So I should use "parent" to tie both kernel and appfs slots to the rootfs?

And for now, the rootfs is r/w on a ext4 filesystem, but in the future it will be a squashfs.  So once that happens would 'type=ext4' then change to 'type=raw'?

Just trying to make sure I understand how to make manifest and system.conf map together for making bundles etc.

Regards,

Brian


Now my problem is the rauc install of the bundle fails:

I'm using rauc 1.5 from Dunfell.

root@imx8mmevk:~# rauc --debug install update-mybundle.raucb  
rauc-Message: 18:58:29.648: Debug log domains: 'rauc'
(rauc:2812): rauc-DEBUG: 18:58:29.655: install started
(rauc:2812): rauc-DEBUG: 18:58:29.655: input bundle: /home/root/update-mybundle.raucb
(rauc:2812): rauc-DEBUG: 18:58:29.667: Trying to contact rauc service
installing
 0% Installing
 0% Determining slot states
20% Determining slot states done.
20% Checking bundle
20% Verifying signature
40% Verifying signature done.
40% Checking bundle done.
40% Checking manifest contents
60% Checking manifest contents done.
60% Determining target install group
80% Determining target install group done.
80% Updating slots
80% Checking slot kernel.1
83% Checking slot kernel.1 done.
83% Copying image to kernel.1
86% Copying image to kernel.1 failed.
100% Updating slots failed.
100% Installing failed.
LastError: Installation error: Failed updating slot kernel.1: failed to run tar extract: Child process exited with code 1
idle
Installing `/home/root/update-mybundle.raucb` failed

My system.conf:

[system]
compatible=MyTarget
bootloader=uboot

[keyring]
path=/etc/rauc/ca.cert.pem

[slot.kernel.0]
device=/dev/mmcblk2gp0p1
type=vfat
parent=rootfs.0

[slot.kernel.1]
device=/dev/mmcblk2gp1p1
type=vfat
parent=rootfs.1

[slot.rootfs.0]
device=/dev/mmcblk2gp0p2
type=ext4
bootname=A

[slot.rootfs.1]
device=/dev/mmcblk2gp1p2
type=ext4
bootname=B

[slot.appfs.0]
device=/dev/mmcblk2p1
type=ext4
parent=rootfs.0

[slot.appfs.1]
device=/dev/mmcblk2p2
type=ext4
parent=rootfs.1

My manifest.rauc:

[update]
compatible=MyTarget
version=2021.06-15

[image.kernel]
sha256=045fb07d617e387e8b39426847a93f517f2af005fb65aced6a7a3028a2adad70
size=21084160
filename=mytarget-fsl-linux-5.4.114.tar.bz2

[image.rootfs]
sha256=d8b18918b7bfeec3f82d8eb454da42aca41da4fc8095cbeb52f4ebce5fb5e29c
size=169139859
filename=mytarget_yocto-3.1.7_dunfell_fslc-linux-5.4.114.tar.bz2

[image.appfs]
sha256=0a46530a2387bd1eafa0912ab00dbc4f21077578f1c0b5e7a3b051b9cc36785a
size=196
filename=mytarget-appfs.tar.bz2

mytarget-fsl-linux-5.4.114.tar.bz2 is a tar of two files (kernel and device tree blob):  Image and imx8mm-evk.dtb

Can I not do a .tar for a vfat target slot?

Regards,

Brian