systemd-sysupdate never writes to the running OS partition. Instead, it requires a separate partition to write the update into. Create a separate partition for that purpose. systemd-sysupdate will fail if the OS image does not fit in the partitions that the installer created. Therefor, make the partitions very large so that there is plenty of room for the OS to grow. This requires rewriting the code that calculates the partition sizes. Signed-off-by: Demi Marie Obenour <demiobenour@gmail.com> --- Changes since v2: - Make into a standalone commit - Do not rely on separate script to generate the images. - Use a smaller size for the verity partition. --- release/live/Makefile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/release/live/Makefile b/release/live/Makefile index a85edfde2d186716656ed23fe719ca63b31bcd59..cf2ace4f5e4ba20a2c0ce9803f72acf0e23f9df3 100644 --- a/release/live/Makefile +++ b/release/live/Makefile @@ -10,12 +10,15 @@ DTBS ?= build/empty dest = build/live.img $(dest): ../../scripts/format-uuid.awk ../../scripts/make-gpt.sh ../../scripts/sfdisk-field.awk build/boot.fat $(ROOT_FS_IMAGES) + # 162MiB was calculated by running `veritysetup format` on 20GiB from /dev/urandom uuids=$$(awk -f ../../scripts/format-uuid.awk < $(ROOT_FS_VERITY_ROOTHASH)) && \ set -euo pipefail -- $$uuids && \ bash ../../scripts/make-gpt.sh $@.tmp \ build/boot.fat:c12a7328-f81f-11d2-ba4b-00a0c93ec93b \ - $(ROOT_FS_VERITY):verity:$$3:Spectrum_'$(VERSION).verity' \ - $(ROOT_FS):root:$$1:Spectrum_'$(VERSION)' + $(ROOT_FS_VERITY):verity:$$3:Spectrum_'$(VERSION).verity:162MiB' \ + $(ROOT_FS):root:$$1:Spectrum_'$(VERSION):20000MiB' \ + $(ROOT_FS_VERITY):verity:$$4:_empty:162MiB \ + $(ROOT_FS):root:$$2:_empty:20000MiB mv $@.tmp $@ build/empty: -- 2.52.0