Skip to content

A/B partition preparation could be done during first boot #47

@m-iwanicki

Description

@m-iwanicki

Currently when we add otab update feature we are creating image with 4 partitions:

  • boot A
  • boot B
  • rootfs A
  • rootfs B

5th partition, rwoverlay, is dynamically created during first boot. We can move boot B and rootfs B creation to either script in initramfs that does this on first boot or better yet, to installer if we implement one.
This would simplify code in Yocto and allow us to modify B slot partitions a little easier, during creation, especially rootfs B. To modify just one file (/etc/fstab) I had to create separate Wic plugin.

The advantage of this feature would be that images (both base and swu update files) would be half their size.

What would need to be done:

  • create slot B partitions dynamically during installation or first boot
  • otab update would need to be modified
    • add only slot A partitions to swu image
    • update sw-description to use the same partition image for both slots
    • update otab-shell post-install script to do what we currently do when preparing second partition e.g. modifying /etc/fstab and command-line in UKI image. Same script/function could be used when preparing slot B, on first boot.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions