Reputation: 2516
I am trying to implement a software update process for a generic x86_64 system using Yocto and SWUpdate. I would like to have two root partitions, with SWUpdate overwriting the inactive one (dual copy strategy). I am trying to create a WIC image to test this in virtualbox (.wic.vdi image)
My problem is in creating the dual rootfs image. So far I have a .wks file:
bootloader --ptable gpt
part /boot --source rootfs --rootfs-dir=${IMAGE_ROOTFS}/boot --sourceparams="loader=grub-efi" --ondisk sda --label msdos --active --align 1024 --use-uuid
part / --source rootfs --fstype=ext4 --label image1 --align 1024 --exclude-path boot/
part / --source rootfs --fstype=ext4 --label image2 --align 1024 --exclude-path boot/
part swap --ondisk sda --size 1024 --label swap --fstype=swap
This creates a wic image with the right partitions, but the bootloader in the first fat partition seems invalid - it does not boot in virtualbox.
If I change the boot partition to
part /boot --source bootimg-efi --sourceparams="loader=grub-efi" --ondisk sda --label msdos --active --align 1024
It will now boot, but I don't have control over the data in the boot partition via bbappends files. I need to be able to edit the grub.cfg and add a grub environment file. As far as I can tell the bootimg-efi is created by the WIC system, so I can't override that easily.
Upvotes: 2
Views: 2978