Repository: systemd/mkosi

Issue:
dm-verity: part-uuid of root partition is not first part of verity roothash
### Short description:

When building an image using `Verity=true`, I would expect the PARTUUID of the root partition to be the first 128 bits of the verity roothash as per the [DISCOVERABLE_PARTITIONS spec](https://systemd.io/DISCOVERABLE_PARTITIONS/).
In reality, the PARTUUID of the root partition seems to be random in my configuration.

### Environment

- Ubuntu 22.04
- mkosi installed from the ubuntu repo https://launchpad.net/ubuntu/+source/mkosi/12-1

### Configuration

```toml
[Distribution]
Distribution=fedora
Release=36

[Partitions]
HomeSize=3G
SrvSize=3G

[Content]
Packages=veritysetup
Password=********

[Output]
ReadOnly=true
Verity=true
Bootable=true

[Host]
QemuHeadless=true
```

<details>
  <summary>Output from <code>mkosi build</code></summary>
  
```shell-session
mkosi build
[sudo] password for malte: 
‣ Removing output files…
‣ Detaching namespace
‣ Setting up package cache…
‣ Setting up package cache /home/malte/projects/mkosi/fedora/.mkosi-h301cl6r complete
‣ Setting up temporary workspace.
‣ Temporary workspace set up in /var/tmp/mkosi-nop2cur_
‣ Running second (final) stage…
‣  Creating image with partition table…
Disk /home/malte/projects/mkosi/fedora/.mkosi-vi0otped: 9,25 GiB, 9932152832 bytes, 19398736 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

>>> Script header accepted.
>>> Script header accepted.
>>> Script header accepted.
>>> Created a new GPT disklabel (GUID: B83B264C-AE83-F943-BDA3-88AB14D42691).
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped1: Created a new partition 1 of type 'EFI System' and of size 256 MiB.
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped2: Created a new partition 2 of type 'Linux home' and of size 3 GiB.
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped3: Created a new partition 3 of type 'Linux server data' and of size 3 GiB.
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped4: Created a new partition 4 of type 'Linux root (x86-64)' and of size 3 GiB.
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped5: Done.

New situation:
Disklabel type: gpt
Disk identifier: B83B264C-AE83-F943-BDA3-88AB14D42691

Device                                                Start      End Sectors  Size Type
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped1       40   524327  524288  256M EFI System
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped2   524328  6815783 6291456    3G Linux home
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped3  6815784 13107239 6291456    3G Linux server data
/home/malte/projects/mkosi/fedora/.mkosi-vi0otped4 13107240 19398695 6291456    3G Linux root (x86-64)

The partition table has been altered.
‣  Created image with partition table as /home/malte/projects/mkosi/fedora/.mkosi-vi0otped
‣  Attaching /home/malte/projects/mkosi/fedora/.mkosi-vi0otped as loopback…
‣  Attached /dev/loop28
‣  Formatting ESP partition
mkfs.fat 4.2 (2021-01-31)
‣  Formatting root partition…
mke2fs 1.46.5 (30-Dec-2021)
Discarding device blocks: done                            
Creating filesystem with 786432 4k blocks and 196608 inodes
Filesystem UUID: 3f716273-57cc-47d3-8a62-599f09357cec
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376, 294912

Allocating group tables: done                            
Writing inode tables: done                            
Creating journal (16384 blocks): done
Writing superblocks and filesystem accounting information: done 

‣  Formatting home partition…
mke2fs 1.46.5 (30-Dec-2021)
Discarding device blocks: done                            
Creating filesystem with 786432 4k blocks and 196608 inodes
Filesystem UUID: 0c87a9d9-10c5-43a7-b3a8-24c873d1332a
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376, 294912

Allocating group tables: done                            
Writing inode tables: done                            
Creating journal (16384 blocks): done
Writing superblocks and filesystem accounting information: done 

‣  Formatting server data partition…
mke2fs 1.46.5 (30-Dec-2021)
Discarding device blocks: done                            
Creating filesystem with 786432 4k blocks and 196608 inodes
Filesystem UUID: 35d929c7-a48b-444f-84ef-f0461c7217e4
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376, 294912

Allocating group tables: done                            
Writing inode tables: done                            
Creating journal (16384 blocks): done
Writing superblocks and filesystem accounting information: done 

‣  Mounting image…
‣  Setting up basic OS tree…
‣  Mounting Package Cache
‣  Installing Fedora Linux…
‣   Mounting API VFS
/usr/lib/python3/dist-packages/dnf/const.py:22: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
  import distutils.sysconfig
/usr/lib/python3/dist-packages/dnf/const.py:22: DeprecationWarning: The distutils.sysconfig module is deprecated, use sysconfig instead
  import distutils.sysconfig
Fedora 36 - base                                                                           6.7 MB/s |  69 MB     00:10    
Fedora 36 - updates                                                                         14 MB/s |  17 MB     00:01    
Last metadata expiration check: 0:00:03 ago on Do 02 Jun 2022 10:19:33 CEST.
Dependencies resolved.
===========================================================================================================================
 Package                                  Architecture      Version                               Repository          Size
===========================================================================================================================
Installing:
[...]

Transaction Summary
===========================================================================================================================
Install  131 Packages

Total download size: 153 M
Installed size: 327 M
Downloading Packages:
[...]
---------------------------------------------------------------------------------------------------------------------------
Total                                                                                       25 MB/s | 153 MB     00:06     
warning: /var/tmp/mkosi-nop2cur_/root/var/cache/dnf/fedora-e58e3c9673d413e5/packages/alternatives-1.19-2.fc36.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 38ab71f4: NOKEY
Fedora 36 - base                                                                            14 MB/s |  14 kB     00:00    
Importing GPG key 0x5323552A:
 Userid     : "Fedora (37) <fedora-37-primary@fedoraproject.org>"
 Fingerprint: ACB5 EE4E 831C 74BB 7C16 8D27 F55A D3FB 5323 552A
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Importing GPG key 0x38AB71F4:
 Userid     : "Fedora (36) <fedora-36-primary@fedoraproject.org>"
 Fingerprint: 53DE D2CB 922D 8B8D 9E63 FD18 999F 7CBF 38AB 71F4
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Importing GPG key 0x9867C58F:
 Userid     : "Fedora (35) <fedora-35-primary@fedoraproject.org>"
 Fingerprint: 787E A6AE 1147 EEE5 6C40 B30C DB46 3971 9867 C58F
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Importing GPG key 0x45719A39:
 Userid     : "Fedora (34) <fedora-34-primary@fedoraproject.org>"
 Fingerprint: 8C5B A699 0BDB 26E1 9F2A 1A80 1161 AE69 4571 9A39
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Importing GPG key 0x9570FF31:
 Userid     : "Fedora (33) <fedora-33-primary@fedoraproject.org>"
 Fingerprint: 963A 2BEB 0200 9608 FE67 EA42 49FD 7749 9570 FF31
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Importing GPG key 0xDBBDCF7C:
 Userid     : "Fedora (iot 2019) <fedora-iot-2019@fedoraproject.org>"
 Fingerprint: C2A3 FA9D C67F 68B9 8BB5 43F4 7BB9 0722 DBBD CF7C
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Importing GPG key 0x3228467C:
 Userid     : "Fedora (epel9) <epel@fedoraproject.org>"
 Fingerprint: FF8A D134 4597 106E CE81 3B91 8A38 72BF 3228 467C
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Importing GPG key 0x2F86D6A1:
 Userid     : "Fedora EPEL (8) <epel@fedoraproject.org>"
 Fingerprint: 94E2 79EB 8D8F 25B2 1810 ADF1 21EA 45AB 2F86 D6A1
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Importing GPG key 0x352C64E5:
 Userid     : "Fedora EPEL (7) <epel@fedoraproject.org>"
 Fingerprint: 91E9 7D7C 4A5E 96F1 7F3E 888F 6A2F AEA2 352C 64E5
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-36-x86_64
Key imported successfully
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Running scriptlet: filesystem-3.16-2.fc36.x86_64                                                                     1/1 
  Preparing        :                                                                                                   1/1 
  Installing       : libgcc-12.1.1-1.fc36.x86_64                                                                     1/131 
  Running scriptlet: libgcc-12.1.1-1.fc36.x86_64                                                                     1/131 
  Installing       : crypto-policies-20220203-2.git112f859.fc36.noarch                                               2/131 
  Running scriptlet: crypto-policies-20220203-2.git112f859.fc36.noarch                                               2/131 
  Installing       : fedora-release-identity-basic-36-17.noarch                                                      3/131 
  Installing       : tzdata-2022a-2.fc36.noarch                                                                      4/131 
  Installing       : pcre2-syntax-10.40-1.fc36.noarch                                                                5/131 
  Installing       : publicsuffix-list-dafsa-20210518-4.fc36.noarch                                                  6/131 
  Installing       : ncurses-base-6.2-9.20210508.fc36.noarch                                                         7/131 
  Installing       : libssh-config-0.9.6-4.fc36.noarch                                                               8/131 
  Installing       : kbd-misc-2.4.0-9.fc36.noarch                                                                    9/131 
  Installing       : fedora-gpg-keys-36-1.noarch                                                                    10/131 
  Installing       : fedora-release-36-17.noarch                                                                    11/131 
  Installing       : fedora-repos-36-1.noarch                                                                       12/131 
  Installing       : fedora-release-common-36-17.noarch                                                             13/131 
  Installing       : setup-2.13.10-1.fc36.noarch                                                                    14/131 
  Running scriptlet: setup-2.13.10-1.fc36.noarch                                                                    14/131 
  Installing       : filesystem-3.16-2.fc36.x86_64                                                                  15/131 
  Installing       : basesystem-11-13.fc36.noarch                                                                   16/131 
  Installing       : bash-5.1.16-2.fc36.x86_64                                                                      17/131 
  Running scriptlet: bash-5.1.16-2.fc36.x86_64                                                                      17/131 
  Installing       : ncurses-libs-6.2-9.20210508.fc36.x86_64                                                        18/131 
  Installing       : glibc-common-2.35-11.fc36.x86_64                                                               19/131 
  Installing       : glibc-minimal-langpack-2.35-11.fc36.x86_64                                                     20/131 
  Running scriptlet: glibc-2.35-11.fc36.x86_64                                                                      21/131 
  Installing       : glibc-2.35-11.fc36.x86_64                                                                      21/131 
  Running scriptlet: glibc-2.35-11.fc36.x86_64                                                                      21/131 
  Installing       : zlib-1.2.11-31.fc36.x86_64                                                                     22/131 
  Installing       : libuuid-2.38-0.2.fc36.x86_64                                                                   23/131 
  Installing       : libcom_err-1.46.5-2.fc36.x86_64                                                                24/131 
  Installing       : xz-libs-5.2.5-9.fc36.x86_64                                                                    25/131 
  Installing       : libxcrypt-4.4.28-1.fc36.x86_64                                                                 26/131 
  Installing       : libzstd-1.5.2-2.fc36.x86_64                                                                    27/131 
  Installing       : elfutils-libelf-0.187-4.fc36.x86_64                                                            28/131 
  Installing       : libcap-2.48-4.fc36.x86_64                                                                      29/131 
  Installing       : bzip2-libs-1.0.8-11.fc36.x86_64                                                                30/131 
  Installing       : gmp-1:6.2.1-2.fc36.x86_64                                                                      31/131 
  Installing       : libattr-2.5.1-4.fc36.x86_64                                                                    32/131 
  Installing       : libacl-2.3.1-3.fc36.x86_64                                                                     33/131 
  Installing       : popt-1.18-7.fc36.x86_64                                                                        34/131 
  Installing       : libcap-ng-0.8.3-1.fc36.x86_64                                                                  35/131 
  Installing       : audit-libs-3.0.8-1.fc36.x86_64                                                                 36/131 
  Installing       : alternatives-1.19-2.fc36.x86_64                                                                37/131 
  Installing       : libsepol-3.3-3.fc36.x86_64                                                                     38/131 
  Installing       : libsmartcols-2.38-0.2.fc36.x86_64                                                              39/131 
  Installing       : libunistring-1.0-1.fc36.x86_64                                                                 40/131 
  Installing       : libidn2-2.3.2-4.fc36.x86_64                                                                    41/131 
  Installing       : lz4-libs-1.9.3-4.fc36.x86_64                                                                   42/131 
  Installing       : readline-8.1-6.fc36.x86_64                                                                     43/131 
  Installing       : libstdc++-12.1.1-1.fc36.x86_64                                                                 44/131 
  Installing       : pcre2-10.40-1.fc36.x86_64                                                                      45/131 
  Installing       : libselinux-3.3-4.fc36.x86_64                                                                   46/131 
  Installing       : sed-4.8-10.fc36.x86_64                                                                         47/131 
  Installing       : findutils-1:4.9.0-1.fc36.x86_64                                                                48/131 
  Installing       : libsemanage-3.3-3.fc36.x86_64                                                                  49/131 
  Installing       : shadow-utils-2:4.11.1-2.fc36.x86_64                                                            50/131 
  Running scriptlet: libutempter-1.2.1-6.fc36.x86_64                                                                51/131 
  Installing       : libutempter-1.2.1-6.fc36.x86_64                                                                51/131 
  Installing       : libpsl-0.21.1-5.fc36.x86_64                                                                    52/131 
  Installing       : mpfr-4.1.0-9.fc36.x86_64                                                                       53/131 
  Installing       : e2fsprogs-libs-1.46.5-2.fc36.x86_64                                                            54/131 
  Installing       : libss-1.46.5-2.fc36.x86_64                                                                     55/131 
  Installing       : cpio-2.13-12.fc36.x86_64                                                                       56/131 
  Installing       : expat-2.4.7-1.fc36.x86_64                                                                      57/131 
  Installing       : fuse-libs-2.9.9-14.fc36.x86_64                                                                 58/131 
  Installing       : gdbm-libs-1:1.22-2.fc36.x86_64                                                                 59/131 
  Installing       : json-c-0.15-3.fc36.x86_64                                                                      60/131 
  Installing       : keyutils-libs-1.6.1-4.fc36.x86_64                                                              61/131 
  Installing       : libbrotli-1.0.9-7.fc36.x86_64                                                                  62/131 
  Installing       : libdb-5.3.28-51.fc36.x86_64                                                                    63/131 
  Installing       : libeconf-0.4.0-3.fc36.x86_64                                                                   64/131 
  Installing       : pam-libs-1.5.2-12.fc36.x86_64                                                                  65/131 
  Installing       : kbd-2.4.0-9.fc36.x86_64                                                                        66/131 
  Installing       : libffi-3.4.2-8.fc36.x86_64                                                                     67/131 
  Installing       : p11-kit-0.24.1-2.fc36.x86_64                                                                   68/131 
  Installing       : libnghttp2-1.46.0-2.fc36.x86_64                                                                69/131 
  Installing       : libseccomp-2.5.3-2.fc36.x86_64                                                                 70/131 
  Installing       : libsigsegv-2.14-2.fc36.x86_64                                                                  71/131 
  Installing       : gawk-5.1.1-2.fc36.x86_64                                                                       72/131 
  Installing       : libtasn1-4.18.0-2.fc36.x86_64                                                                  73/131 
  Installing       : p11-kit-trust-0.24.1-2.fc36.x86_64                                                             74/131 
  Running scriptlet: p11-kit-trust-0.24.1-2.fc36.x86_64                                                             74/131 
  Installing       : libverto-0.3.2-3.fc36.x86_64                                                                   75/131 
  Installing       : pcre-8.45-1.fc36.1.x86_64                                                                      76/131 
  Installing       : grep-3.7-2.fc36.x86_64                                                                         77/131 
  Installing       : xz-5.2.5-9.fc36.x86_64                                                                         78/131 
  Installing       : libargon2-20171227-9.fc36.x86_64                                                               79/131 
  Installing       : libgpg-error-1.45-1.fc36.x86_64                                                                80/131 
  Installing       : libgcrypt-1.10.1-2.fc36.x86_64                                                                 81/131 
  Installing       : systemd-libs-250.6-1.fc36.x86_64                                                               82/131 
  Installing       : procps-ng-3.3.17-4.fc36.x86_64                                                                 83/131 
  Installing       : dbus-common-1:1.14.0-1.fc36.noarch                                                             84/131 
  Running scriptlet: dbus-common-1:1.14.0-1.fc36.noarch                                                             84/131 
  Running scriptlet: dbus-broker-31-1.fc36.x86_64                                                                   85/131 
useradd warning: dbus's uid 81 outside of the SYS_UID_MIN 201 and SYS_UID_MAX 999 range.

  Installing       : dbus-broker-31-1.fc36.x86_64                                                                   85/131 
  Running scriptlet: dbus-broker-31-1.fc36.x86_64                                                                   85/131 
  Installing       : dbus-1:1.14.0-1.fc36.x86_64                                                                    86/131 
  Installing       : coreutils-common-9.0-5.fc36.x86_64                                                             87/131 
  Installing       : openssl-libs-1:3.0.2-5.fc36.x86_64                                                             88/131 
  Installing       : coreutils-9.0-5.fc36.x86_64                                                                    89/131 
  Running scriptlet: ca-certificates-2021.2.52-3.fc36.noarch                                                        90/131 
  Installing       : ca-certificates-2021.2.52-3.fc36.noarch                                                        90/131 
  Running scriptlet: ca-certificates-2021.2.52-3.fc36.noarch                                                        90/131 
  Installing       : libblkid-2.38-0.2.fc36.x86_64                                                                  91/131 
  Running scriptlet: libblkid-2.38-0.2.fc36.x86_64                                                                  91/131 
  Installing       : krb5-libs-1.19.2-9.fc36.x86_64                                                                 92/131 
  Installing       : libfdisk-2.38-0.2.fc36.x86_64                                                                  93/131 
  Installing       : libmount-2.38-0.2.fc36.x86_64                                                                  94/131 
  Installing       : util-linux-core-2.38-0.2.fc36.x86_64                                                           95/131 
  Running scriptlet: util-linux-core-2.38-0.2.fc36.x86_64                                                           95/131 
  Installing       : kmod-libs-29-7.fc36.x86_64                                                                     96/131 
  Installing       : libtirpc-1.3.2-1.rc1.fc36.1.x86_64                                                             97/131 
  Installing       : gzip-1.11-3.fc36.x86_64                                                                        98/131 
  Installing       : cracklib-2.9.6-28.fc36.x86_64                                                                  99/131 
  Installing       : kmod-29-7.fc36.x86_64                                                                         100/131 
  Installing       : cracklib-dicts-2.9.6-28.fc36.x86_64                                                           101/131 
  Installing       : libnsl2-2.0.0-3.fc36.x86_64                                                                   102/131 
  Installing       : cyrus-sasl-lib-2.1.27-18.fc36.x86_64                                                          103/131 
  Installing       : libssh-0.9.6-4.fc36.x86_64                                                                    104/131 
  Installing       : libevent-2.1.12-6.fc36.x86_64                                                                 105/131 
  Installing       : openldap-2.6.2-1.fc36.x86_64                                                                  106/131 
  Installing       : libcurl-7.82.0-5.fc36.x86_64                                                                  107/131 
  Installing       : cryptsetup-libs-2.4.3-2.fc36.x86_64                                                           108/131 
  Installing       : device-mapper-libs-1.02.175-7.fc36.x86_64                                                     109/131 
  Installing       : device-mapper-1.02.175-7.fc36.x86_64                                                          110/131 
  Installing       : libpwquality-1.4.4-7.fc36.x86_64                                                              111/131 
  Installing       : util-linux-2.38-0.2.fc36.x86_64                                                               112/131 
  Installing       : pam-1.5.2-12.fc36.x86_64                                                                      113/131 
  Installing       : authselect-1.4.0-1.fc36.x86_64                                                                114/131 
  Running scriptlet: authselect-libs-1.4.0-1.fc36.x86_64                                                           115/131 
  Installing       : authselect-libs-1.4.0-1.fc36.x86_64                                                           115/131 
  Installing       : elfutils-debuginfod-client-0.187-4.fc36.x86_64                                                116/131 
  Installing       : elfutils-libs-0.187-4.fc36.x86_64                                                             117/131 
  Installing       : elfutils-default-yama-scope-0.187-4.fc36.noarch                                               118/131 
  Running scriptlet: elfutils-default-yama-scope-0.187-4.fc36.noarch                                               118/131 
  Installing       : systemd-pam-250.6-1.fc36.x86_64                                                               119/131 
  Installing       : systemd-250.6-1.fc36.x86_64                                                                   120/131 
  Running scriptlet: systemd-250.6-1.fc36.x86_64                                                                   120/131 
Creating group 'input' with GID 104.
Creating group 'kvm' with GID 36.
Creating group 'render' with GID 105.
Creating group 'sgx' with GID 106.
Creating group 'systemd-journal' with GID 190.
Creating group 'systemd-network' with GID 192.
Creating user 'systemd-network' (systemd Network Management) with UID 192 and GID 192.
Creating group 'systemd-oom' with GID 999.
Creating user 'systemd-oom' (systemd Userspace OOM Killer) with UID 999 and GID 999.

  Installing       : systemd-udev-250.6-1.fc36.x86_64                                                              121/131 
  Running scriptlet: systemd-udev-250.6-1.fc36.x86_64                                                              121/131 
Created symlink /etc/systemd/system/sysinit.target.wants/systemd-boot-update.service → /usr/lib/systemd/system/systemd-boot-update.service.

  Installing       : libkcapi-1.3.1-4.fc36.x86_64                                                                  122/131 
  Installing       : libkcapi-hmaccalc-1.3.1-4.fc36.x86_64                                                         123/131 
  Installing       : dracut-056-1.fc36.x86_64                                                                      124/131 
  Installing       : kernel-core-5.17.11-300.fc36.x86_64                                                           125/131 
  Running scriptlet: kernel-core-5.17.11-300.fc36.x86_64                                                           125/131 
  Installing       : binutils-gold-2.37-27.fc36.x86_64                                                             126/131 
  Installing       : binutils-2.37-27.fc36.x86_64                                                                  127/131 
  Running scriptlet: binutils-2.37-27.fc36.x86_64                                                                  127/131 
  Installing       : kernel-modules-5.17.11-300.fc36.x86_64                                                        128/131 
  Running scriptlet: kernel-modules-5.17.11-300.fc36.x86_64                                                        128/131 
  Installing       : cryptsetup-2.4.3-2.fc36.x86_64                                                                129/131 
  Installing       : veritysetup-2.4.3-2.fc36.x86_64                                                               130/131 
  Installing       : e2fsprogs-1.46.5-2.fc36.x86_64                                                                131/131 
  Running scriptlet: filesystem-3.16-2.fc36.x86_64                                                                 131/131 
  Running scriptlet: ca-certificates-2021.2.52-3.fc36.noarch                                                       131/131 
  Running scriptlet: authselect-libs-1.4.0-1.fc36.x86_64                                                           131/131 
  Running scriptlet: kernel-core-5.17.11-300.fc36.x86_64                                                           131/131 
  Running scriptlet: kernel-modules-5.17.11-300.fc36.x86_64                                                        131/131 
  Running scriptlet: e2fsprogs-1.46.5-2.fc36.x86_64                                                                131/131 
Creating group 'systemd-coredump' with GID 998.
Creating user 'systemd-coredump' (systemd Core Dumper) with UID 998 and GID 998.
Creating group 'systemd-timesync' with GID 997.
Creating user 'systemd-timesync' (systemd Time Synchronization) with UID 997 and GID 997.

  Verifying        : alternatives-1.19-2.fc36.x86_64                                                                 1/131 
  Verifying        : audit-libs-3.0.8-1.fc36.x86_64                                                                  2/131 
  Verifying        : basesystem-11-13.fc36.noarch                                                                    3/131 
  Verifying        : bash-5.1.16-2.fc36.x86_64                                                                       4/131 
  Verifying        : bzip2-libs-1.0.8-11.fc36.x86_64                                                                 5/131 
  Verifying        : ca-certificates-2021.2.52-3.fc36.noarch                                                         6/131 
  Verifying        : coreutils-9.0-5.fc36.x86_64                                                                     7/131 
  Verifying        : coreutils-common-9.0-5.fc36.x86_64                                                              8/131 
  Verifying        : cpio-2.13-12.fc36.x86_64                                                                        9/131 
  Verifying        : cracklib-2.9.6-28.fc36.x86_64                                                                  10/131 
  Verifying        : cracklib-dicts-2.9.6-28.fc36.x86_64                                                            11/131 
  Verifying        : crypto-policies-20220203-2.git112f859.fc36.noarch                                              12/131 
  Verifying        : cryptsetup-2.4.3-2.fc36.x86_64                                                                 13/131 
  Verifying        : cryptsetup-libs-2.4.3-2.fc36.x86_64                                                            14/131 
  Verifying        : cyrus-sasl-lib-2.1.27-18.fc36.x86_64                                                           15/131 
  Verifying        : dbus-1:1.14.0-1.fc36.x86_64                                                                    16/131 
  Verifying        : dbus-common-1:1.14.0-1.fc36.noarch                                                             17/131 
  Verifying        : device-mapper-1.02.175-7.fc36.x86_64                                                           18/131 
  Verifying        : device-mapper-libs-1.02.175-7.fc36.x86_64                                                      19/131 
  Verifying        : dracut-056-1.fc36.x86_64                                                                       20/131 
  Verifying        : e2fsprogs-1.46.5-2.fc36.x86_64                                                                 21/131 
  Verifying        : e2fsprogs-libs-1.46.5-2.fc36.x86_64                                                            22/131 
  Verifying        : expat-2.4.7-1.fc36.x86_64                                                                      23/131 
  Verifying        : fedora-gpg-keys-36-1.noarch                                                                    24/131 
  Verifying        : fedora-release-36-17.noarch                                                                    25/131 
  Verifying        : fedora-release-common-36-17.noarch                                                             26/131 
  Verifying        : fedora-release-identity-basic-36-17.noarch                                                     27/131 
  Verifying        : fedora-repos-36-1.noarch                                                                       28/131 
  Verifying        : filesystem-3.16-2.fc36.x86_64                                                                  29/131 
  Verifying        : findutils-1:4.9.0-1.fc36.x86_64                                                                30/131 
  Verifying        : fuse-libs-2.9.9-14.fc36.x86_64                                                                 31/131 
  Verifying        : gawk-5.1.1-2.fc36.x86_64                                                                       32/131 
  Verifying        : gdbm-libs-1:1.22-2.fc36.x86_64                                                                 33/131 
  Verifying        : gmp-1:6.2.1-2.fc36.x86_64                                                                      34/131 
  Verifying        : grep-3.7-2.fc36.x86_64                                                                         35/131 
  Verifying        : gzip-1.11-3.fc36.x86_64                                                                        36/131 
  Verifying        : json-c-0.15-3.fc36.x86_64                                                                      37/131 
  Verifying        : kbd-2.4.0-9.fc36.x86_64                                                                        38/131 
  Verifying        : kbd-misc-2.4.0-9.fc36.noarch                                                                   39/131 
  Verifying        : keyutils-libs-1.6.1-4.fc36.x86_64                                                              40/131 
  Verifying        : kmod-29-7.fc36.x86_64                                                                          41/131 
  Verifying        : kmod-libs-29-7.fc36.x86_64                                                                     42/131 
  Verifying        : libacl-2.3.1-3.fc36.x86_64                                                                     43/131 
  Verifying        : libattr-2.5.1-4.fc36.x86_64                                                                    44/131 
  Verifying        : libblkid-2.38-0.2.fc36.x86_64                                                                  45/131 
  Verifying        : libbrotli-1.0.9-7.fc36.x86_64                                                                  46/131 
  Verifying        : libcap-2.48-4.fc36.x86_64                                                                      47/131 
  Verifying        : libcom_err-1.46.5-2.fc36.x86_64                                                                48/131 
  Verifying        : libdb-5.3.28-51.fc36.x86_64                                                                    49/131 
  Verifying        : libeconf-0.4.0-3.fc36.x86_64                                                                   50/131 
  Verifying        : libevent-2.1.12-6.fc36.x86_64                                                                  51/131 
  Verifying        : libfdisk-2.38-0.2.fc36.x86_64                                                                  52/131 
  Verifying        : libffi-3.4.2-8.fc36.x86_64                                                                     53/131 
  Verifying        : libidn2-2.3.2-4.fc36.x86_64                                                                    54/131 
  Verifying        : libkcapi-1.3.1-4.fc36.x86_64                                                                   55/131 
  Verifying        : libkcapi-hmaccalc-1.3.1-4.fc36.x86_64                                                          56/131 
  Verifying        : libmount-2.38-0.2.fc36.x86_64                                                                  57/131 
  Verifying        : libnghttp2-1.46.0-2.fc36.x86_64                                                                58/131 
  Verifying        : libnsl2-2.0.0-3.fc36.x86_64                                                                    59/131 
  Verifying        : libpsl-0.21.1-5.fc36.x86_64                                                                    60/131 
  Verifying        : libpwquality-1.4.4-7.fc36.x86_64                                                               61/131 
  Verifying        : libseccomp-2.5.3-2.fc36.x86_64                                                                 62/131 
  Verifying        : libselinux-3.3-4.fc36.x86_64                                                                   63/131 
  Verifying        : libsemanage-3.3-3.fc36.x86_64                                                                  64/131 
  Verifying        : libsepol-3.3-3.fc36.x86_64                                                                     65/131 
  Verifying        : libsigsegv-2.14-2.fc36.x86_64                                                                  66/131 
  Verifying        : libsmartcols-2.38-0.2.fc36.x86_64                                                              67/131 
  Verifying        : libss-1.46.5-2.fc36.x86_64                                                                     68/131 
  Verifying        : libssh-0.9.6-4.fc36.x86_64                                                                     69/131 
  Verifying        : libssh-config-0.9.6-4.fc36.noarch                                                              70/131 
  Verifying        : libtasn1-4.18.0-2.fc36.x86_64                                                                  71/131 
  Verifying        : libtirpc-1.3.2-1.rc1.fc36.1.x86_64                                                             72/131 
  Verifying        : libunistring-1.0-1.fc36.x86_64                                                                 73/131 
  Verifying        : libutempter-1.2.1-6.fc36.x86_64                                                                74/131 
  Verifying        : libuuid-2.38-0.2.fc36.x86_64                                                                   75/131 
  Verifying        : libverto-0.3.2-3.fc36.x86_64                                                                   76/131 
  Verifying        : libxcrypt-4.4.28-1.fc36.x86_64                                                                 77/131 
  Verifying        : lz4-libs-1.9.3-4.fc36.x86_64                                                                   78/131 
  Verifying        : mpfr-4.1.0-9.fc36.x86_64                                                                       79/131 
  Verifying        : ncurses-base-6.2-9.20210508.fc36.noarch                                                        80/131 
  Verifying        : ncurses-libs-6.2-9.20210508.fc36.x86_64                                                        81/131 
  Verifying        : p11-kit-0.24.1-2.fc36.x86_64                                                                   82/131 
  Verifying        : p11-kit-trust-0.24.1-2.fc36.x86_64                                                             83/131 
  Verifying        : pam-1.5.2-12.fc36.x86_64                                                                       84/131 
  Verifying        : pam-libs-1.5.2-12.fc36.x86_64                                                                  85/131 
  Verifying        : pcre-8.45-1.fc36.1.x86_64                                                                      86/131 
  Verifying        : popt-1.18-7.fc36.x86_64                                                                        87/131 
  Verifying        : procps-ng-3.3.17-4.fc36.x86_64                                                                 88/131 
  Verifying        : publicsuffix-list-dafsa-20210518-4.fc36.noarch                                                 89/131 
  Verifying        : readline-8.1-6.fc36.x86_64                                                                     90/131 
  Verifying        : sed-4.8-10.fc36.x86_64                                                                         91/131 
  Verifying        : shadow-utils-2:4.11.1-2.fc36.x86_64                                                            92/131 
  Verifying        : util-linux-2.38-0.2.fc36.x86_64                                                                93/131 
  Verifying        : util-linux-core-2.38-0.2.fc36.x86_64                                                           94/131 
  Verifying        : veritysetup-2.4.3-2.fc36.x86_64                                                                95/131 
  Verifying        : xz-5.2.5-9.fc36.x86_64                                                                         96/131 
  Verifying        : xz-libs-5.2.5-9.fc36.x86_64                                                                    97/131 
  Verifying        : zlib-1.2.11-31.fc36.x86_64                                                                     98/131 
  Verifying        : authselect-1.4.0-1.fc36.x86_64                                                                 99/131 
  Verifying        : authselect-libs-1.4.0-1.fc36.x86_64                                                           100/131 
  Verifying        : binutils-2.37-27.fc36.x86_64                                                                  101/131 
  Verifying        : binutils-gold-2.37-27.fc36.x86_64                                                             102/131 
  Verifying        : dbus-broker-31-1.fc36.x86_64                                                                  103/131 
  Verifying        : elfutils-debuginfod-client-0.187-4.fc36.x86_64                                                104/131 
  Verifying        : elfutils-default-yama-scope-0.187-4.fc36.noarch                                               105/131 
  Verifying        : elfutils-libelf-0.187-4.fc36.x86_64                                                           106/131 
  Verifying        : elfutils-libs-0.187-4.fc36.x86_64                                                             107/131 
  Verifying        : glibc-2.35-11.fc36.x86_64                                                                     108/131 
  Verifying        : glibc-common-2.35-11.fc36.x86_64                                                              109/131 
  Verifying        : glibc-minimal-langpack-2.35-11.fc36.x86_64                                                    110/131 
  Verifying        : kernel-core-5.17.11-300.fc36.x86_64                                                           111/131 
  Verifying        : kernel-modules-5.17.11-300.fc36.x86_64                                                        112/131 
  Verifying        : krb5-libs-1.19.2-9.fc36.x86_64                                                                113/131 
  Verifying        : libargon2-20171227-9.fc36.x86_64                                                              114/131 
  Verifying        : libcap-ng-0.8.3-1.fc36.x86_64                                                                 115/131 
  Verifying        : libcurl-7.82.0-5.fc36.x86_64                                                                  116/131 
  Verifying        : libgcc-12.1.1-1.fc36.x86_64                                                                   117/131 
  Verifying        : libgcrypt-1.10.1-2.fc36.x86_64                                                                118/131 
  Verifying        : libgpg-error-1.45-1.fc36.x86_64                                                               119/131 
  Verifying        : libstdc++-12.1.1-1.fc36.x86_64                                                                120/131 
  Verifying        : libzstd-1.5.2-2.fc36.x86_64                                                                   121/131 
  Verifying        : openldap-2.6.2-1.fc36.x86_64                                                                  122/131 
  Verifying        : openssl-libs-1:3.0.2-5.fc36.x86_64                                                            123/131 
  Verifying        : pcre2-10.40-1.fc36.x86_64                                                                     124/131 
  Verifying        : pcre2-syntax-10.40-1.fc36.noarch                                                              125/131 
  Verifying        : setup-2.13.10-1.fc36.noarch                                                                   126/131 
  Verifying        : systemd-250.6-1.fc36.x86_64                                                                   127/131 
  Verifying        : systemd-libs-250.6-1.fc36.x86_64                                                              128/131 
  Verifying        : systemd-pam-250.6-1.fc36.x86_64                                                               129/131 
  Verifying        : systemd-udev-250.6-1.fc36.x86_64                                                              130/131 
  Verifying        : tzdata-2022a-2.fc36.noarch                                                                    131/131 

Installed:
  alternatives-1.19-2.fc36.x86_64                             audit-libs-3.0.8-1.fc36.x86_64                               
  authselect-1.4.0-1.fc36.x86_64                              authselect-libs-1.4.0-1.fc36.x86_64                          
  basesystem-11-13.fc36.noarch                                bash-5.1.16-2.fc36.x86_64                                    
  binutils-2.37-27.fc36.x86_64                                binutils-gold-2.37-27.fc36.x86_64                            
  bzip2-libs-1.0.8-11.fc36.x86_64                             ca-certificates-2021.2.52-3.fc36.noarch                      
  coreutils-9.0-5.fc36.x86_64                                 coreutils-common-9.0-5.fc36.x86_64                           
  cpio-2.13-12.fc36.x86_64                                    cracklib-2.9.6-28.fc36.x86_64                                
  cracklib-dicts-2.9.6-28.fc36.x86_64                         crypto-policies-20220203-2.git112f859.fc36.noarch            
  cryptsetup-2.4.3-2.fc36.x86_64                              cryptsetup-libs-2.4.3-2.fc36.x86_64                          
  cyrus-sasl-lib-2.1.27-18.fc36.x86_64                        dbus-1:1.14.0-1.fc36.x86_64                                  
  dbus-broker-31-1.fc36.x86_64                                dbus-common-1:1.14.0-1.fc36.noarch                           
  device-mapper-1.02.175-7.fc36.x86_64                        device-mapper-libs-1.02.175-7.fc36.x86_64                    
  dracut-056-1.fc36.x86_64                                    e2fsprogs-1.46.5-2.fc36.x86_64                               
  e2fsprogs-libs-1.46.5-2.fc36.x86_64                         elfutils-debuginfod-client-0.187-4.fc36.x86_64               
  elfutils-default-yama-scope-0.187-4.fc36.noarch             elfutils-libelf-0.187-4.fc36.x86_64                          
  elfutils-libs-0.187-4.fc36.x86_64                           expat-2.4.7-1.fc36.x86_64                                    
  fedora-gpg-keys-36-1.noarch                                 fedora-release-36-17.noarch                                  
  fedora-release-common-36-17.noarch                          fedora-release-identity-basic-36-17.noarch                   
  fedora-repos-36-1.noarch                                    filesystem-3.16-2.fc36.x86_64                                
  findutils-1:4.9.0-1.fc36.x86_64                             fuse-libs-2.9.9-14.fc36.x86_64                               
  gawk-5.1.1-2.fc36.x86_64                                    gdbm-libs-1:1.22-2.fc36.x86_64                               
  glibc-2.35-11.fc36.x86_64                                   glibc-common-2.35-11.fc36.x86_64                             
  glibc-minimal-langpack-2.35-11.fc36.x86_64                  gmp-1:6.2.1-2.fc36.x86_64                                    
  grep-3.7-2.fc36.x86_64                                      gzip-1.11-3.fc36.x86_64                                      
  json-c-0.15-3.fc36.x86_64                                   kbd-2.4.0-9.fc36.x86_64                                      
  kbd-misc-2.4.0-9.fc36.noarch                                kernel-core-5.17.11-300.fc36.x86_64                          
  kernel-modules-5.17.11-300.fc36.x86_64                      keyutils-libs-1.6.1-4.fc36.x86_64                            
  kmod-29-7.fc36.x86_64                                       kmod-libs-29-7.fc36.x86_64                                   
  krb5-libs-1.19.2-9.fc36.x86_64                              libacl-2.3.1-3.fc36.x86_64                                   
  libargon2-20171227-9.fc36.x86_64                            libattr-2.5.1-4.fc36.x86_64                                  
  libblkid-2.38-0.2.fc36.x86_64                               libbrotli-1.0.9-7.fc36.x86_64                                
  libcap-2.48-4.fc36.x86_64                                   libcap-ng-0.8.3-1.fc36.x86_64                                
  libcom_err-1.46.5-2.fc36.x86_64                             libcurl-7.82.0-5.fc36.x86_64                                 
  libdb-5.3.28-51.fc36.x86_64                                 libeconf-0.4.0-3.fc36.x86_64                                 
  libevent-2.1.12-6.fc36.x86_64                               libfdisk-2.38-0.2.fc36.x86_64                                
  libffi-3.4.2-8.fc36.x86_64                                  libgcc-12.1.1-1.fc36.x86_64                                  
  libgcrypt-1.10.1-2.fc36.x86_64                              libgpg-error-1.45-1.fc36.x86_64                              
  libidn2-2.3.2-4.fc36.x86_64                                 libkcapi-1.3.1-4.fc36.x86_64                                 
  libkcapi-hmaccalc-1.3.1-4.fc36.x86_64                       libmount-2.38-0.2.fc36.x86_64                                
  libnghttp2-1.46.0-2.fc36.x86_64                             libnsl2-2.0.0-3.fc36.x86_64                                  
  libpsl-0.21.1-5.fc36.x86_64                                 libpwquality-1.4.4-7.fc36.x86_64                             
  libseccomp-2.5.3-2.fc36.x86_64                              libselinux-3.3-4.fc36.x86_64                                 
  libsemanage-3.3-3.fc36.x86_64                               libsepol-3.3-3.fc36.x86_64                                   
  libsigsegv-2.14-2.fc36.x86_64                               libsmartcols-2.38-0.2.fc36.x86_64                            
  libss-1.46.5-2.fc36.x86_64                                  libssh-0.9.6-4.fc36.x86_64                                   
  libssh-config-0.9.6-4.fc36.noarch                           libstdc++-12.1.1-1.fc36.x86_64                               
  libtasn1-4.18.0-2.fc36.x86_64                               libtirpc-1.3.2-1.rc1.fc36.1.x86_64                           
  libunistring-1.0-1.fc36.x86_64                              libutempter-1.2.1-6.fc36.x86_64                              
  libuuid-2.38-0.2.fc36.x86_64                                libverto-0.3.2-3.fc36.x86_64                                 
  libxcrypt-4.4.28-1.fc36.x86_64                              libzstd-1.5.2-2.fc36.x86_64                                  
  lz4-libs-1.9.3-4.fc36.x86_64                                mpfr-4.1.0-9.fc36.x86_64                                     
  ncurses-base-6.2-9.20210508.fc36.noarch                     ncurses-libs-6.2-9.20210508.fc36.x86_64                      
  openldap-2.6.2-1.fc36.x86_64                                openssl-libs-1:3.0.2-5.fc36.x86_64                           
  p11-kit-0.24.1-2.fc36.x86_64                                p11-kit-trust-0.24.1-2.fc36.x86_64                           
  pam-1.5.2-12.fc36.x86_64                                    pam-libs-1.5.2-12.fc36.x86_64                                
  pcre-8.45-1.fc36.1.x86_64                                   pcre2-10.40-1.fc36.x86_64                                    
  pcre2-syntax-10.40-1.fc36.noarch                            popt-1.18-7.fc36.x86_64                                      
  procps-ng-3.3.17-4.fc36.x86_64                              publicsuffix-list-dafsa-20210518-4.fc36.noarch               
  readline-8.1-6.fc36.x86_64                                  sed-4.8-10.fc36.x86_64                                       
  setup-2.13.10-1.fc36.noarch                                 shadow-utils-2:4.11.1-2.fc36.x86_64                          
  systemd-250.6-1.fc36.x86_64                                 systemd-libs-250.6-1.fc36.x86_64                             
  systemd-pam-250.6-1.fc36.x86_64                             systemd-udev-250.6-1.fc36.x86_64                             
  tzdata-2022a-2.fc36.noarch                                  util-linux-2.38-0.2.fc36.x86_64                              
  util-linux-core-2.38-0.2.fc36.x86_64                        veritysetup-2.4.3-2.fc36.x86_64                              
  xz-5.2.5-9.fc36.x86_64                                      xz-libs-5.2.5-9.fc36.x86_64                                  
  zlib-1.2.11-31.fc36.x86_64                                 

Complete!
‣   Unmounting API VFS
‣  Unmounting Package Cache
‣  Installing boot loader…
Copied "/usr/lib/systemd/boot/efi/systemd-bootx64.efi" to "/efi/EFI/systemd/systemd-bootx64.efi".
Copied "/usr/lib/systemd/boot/efi/systemd-bootx64.efi" to "/efi/EFI/BOOT/BOOTX64.EFI".
Updated /etc/machine-info with KERNEL_INSTALL_LAYOUT=bls
Random seed file /efi/loader/random-seed successfully written (512 bytes).
‣  Setting root password
‣  Configuring serial tty (/dev/ttyS0)…
‣  Recording packages in manifest…
‣  Cleaning dnf metadata…
‣  Resetting machine ID
‣  Removing random seed
‣  Trimming File System
/var/tmp/mkosi-nop2cur_/root: 2,8 GiB (2990616576 bytes) trimmed
‣  Unmounting image
‣  Generating verity hashes…
‣  Patching root partition UUID…
Partition UUID changed from 7710516E-9A4E-534C-BC4C-E9E94E13F0D1 to B180BB0B-8421-28DF-ABEF-5A9CD37ABBA0.

The partition table has been altered.
Calling ioctl() to re-read partition table.
Syncing disks.
‣  Inserting verity partition…
‣   Resizing disk image to 9.3G
‣   Inserting partition of 24.2M...
GPT PMBR size mismatch (19398735 != 19448287) will be corrected by write.
The backup GPT table is not on the end of the device. This problem will be corrected by write.
Disk /dev/loop28: 9,27 GiB, 9957523456 bytes, 19448288 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: B83B264C-AE83-F943-BDA3-88AB14D42691

Old situation:

Device           Start      End Sectors  Size Type
/dev/loop28p1       40   524327  524288  256M EFI System
/dev/loop28p2   524328  6815783 6291456    3G Linux home
/dev/loop28p3  6815784 13107239 6291456    3G Linux server data
/dev/loop28p4 13107240 19398695 6291456    3G Linux root (x86-64)

>>> Script header accepted.
>>> Script header accepted.
>>> Script header accepted.
>>> Created a new GPT disklabel (GUID: 4EEBBC79-6ACC-E342-AF07-37E89EAD65A6).
/dev/loop28p1: Created a new partition 1 of type 'EFI System' and of size 256 MiB.
Partition #1 contains a vfat signature.
/dev/loop28p2: Created a new partition 2 of type 'Linux home' and of size 3 GiB.
Partition #2 contains a ext4 signature.
/dev/loop28p3: Created a new partition 3 of type 'Linux server data' and of size 3 GiB.
Partition #3 contains a ext4 signature.
/dev/loop28p4: Created a new partition 4 of type 'Linux root (x86-64)' and of size 3 GiB.
Partition #4 contains a ext4 signature.
/dev/loop28p5: Created a new partition 5 of type 'Linux root verity (x86-64)' and of size 24,2 MiB.
/dev/loop28p6: Done.

New situation:
Disklabel type: gpt
Disk identifier: 4EEBBC79-6ACC-E342-AF07-37E89EAD65A6

Device           Start      End Sectors  Size Type
/dev/loop28p1       40   524327  524288  256M EFI System
/dev/loop28p2   524328  6815783 6291456    3G Linux home
/dev/loop28p3  6815784 13107239 6291456    3G Linux server data
/dev/loop28p4 13107240 19398695 6291456    3G Linux root (x86-64)
/dev/loop28p5 19398696 19448247   49552 24,2M Linux root verity (x86-64)

The partition table has been altered.
blockdev: ioctl error on BLKRRPART: Device or resource busy
blockdev: ioctl error on BLKRRPART: Device or resource busy
blockdev: ioctl error on BLKRRPART: Device or resource busy
blockdev: ioctl error on BLKRRPART: Device or resource busy
‣   Writing partition...
‣  Mounting image…
‣  Generating combined kernel + initrd boot file…
‣  Unmounting image
‣  Detaching /dev/loop28
‣ Digging holes into output file /home/malte/projects/mkosi/fedora/.mkosi-vi0otped…
‣ Writing .roothash file…
‣ Linking image file…
‣  Changing ownership of output file image.raw to user malte (acquired from sudo)…
‣  Changed ownership of image.raw
‣ Linked image.raw
‣ Linking .roothash file…
‣  Changing ownership of output file image.roothash to user malte (acquired from sudo)…
‣  Changed ownership of image.roothash
‣ Linked image.roothash
‣ Root hash is b180bb0b842128dfabef5a9cd37abba06f2870d3f88166ec531c1ba3d198592c.
‣ Saving manifest image.raw.manifest
‣  Changing ownership of output file image.raw.manifest to user malte (acquired from sudo)…
‣  Changed ownership of image.raw.manifest
‣ Resulting image size is 9.3G, consumes 529.0M.
```
</details>

### Manual fix

By changing the root disk uuid manually, it is possible to get the desired DISCOVERABLE_PARTITIONS layout.

```shell-session
# sfdisk -d image.raw
label: gpt
label-id: 4EEBBC79-6ACC-E342-AF07-37E89EAD65A6
device: image.raw
unit: sectors
first-lba: 40
last-lba: 19448254
sector-size: 512

image.raw1 : start=          40, size=      524288, type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B, uuid=58A0002F-4D20-C04F-9E10-51EB162200CF, name="ESP System Partition"
image.raw2 : start=      524328, size=     6291456, type=933AC7E1-2EB4-4F13-B844-0E14E2AEF915, uuid=EC038E80-6E05-AD46-9BE0-B4660125E4E7, name="Home Partition"
image.raw3 : start=     6815784, size=     6291456, type=3B8F8425-20E0-4F3B-907F-1A25A76F98E8, uuid=2E1454DD-E1F7-944B-ADEE-9316E280E4FB, name="Server Data Partition"
image.raw4 : start=    13107240, size=     6291456, type=4F68BCE3-E8CD-4DB1-96E7-FBCAF984B709, uuid=F7DE420C-2C18-7E49-84BF-37CABDA29FFE, name="Root Partition", attrs="GUID:60"
image.raw5 : start=    19398696, size=       49552, type=2C7357ED-EBD2-46D9-AEC1-23D437EC2BF5, uuid=6F2870D3-F881-66EC-531C-1BA3D198592C, name="Root Verity"

# sfdisk --part-uuid image.raw 4 b180bb0b-8421-28df-abef-5a9cd37abba0
Partition UUID changed from F7DE420C-2C18-7E49-84BF-37CABDA29FFE to B180BB0B-8421-28DF-ABEF-5A9CD37ABBA0.

The partition table has been altered.
Syncing disks.

# sfdisk -d image.raw
label: gpt
label-id: 4EEBBC79-6ACC-E342-AF07-37E89EAD65A6
device: image.raw
unit: sectors
first-lba: 40
last-lba: 19448254
sector-size: 512

image.raw1 : start=          40, size=      524288, type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B, uuid=58A0002F-4D20-C04F-9E10-51EB162200CF, name="ESP System Partition"
image.raw2 : start=      524328, size=     6291456, type=933AC7E1-2EB4-4F13-B844-0E14E2AEF915, uuid=EC038E80-6E05-AD46-9BE0-B4660125E4E7, name="Home Partition"
image.raw3 : start=     6815784, size=     6291456, type=3B8F8425-20E0-4F3B-907F-1A25A76F98E8, uuid=2E1454DD-E1F7-944B-ADEE-9316E280E4FB, name="Server Data Partition"
image.raw4 : start=    13107240, size=     6291456, type=4F68BCE3-E8CD-4DB1-96E7-FBCAF984B709, uuid=B180BB0B-8421-28DF-ABEF-5A9CD37ABBA0, name="Root Partition", attrs="GUID:60"
image.raw5 : start=    19398696, size=       49552, type=2C7357ED-EBD2-46D9-AEC1-23D437EC2BF5, uuid=6F2870D3-F881-66EC-531C-1BA3D198592C, name="Root Verity"
```

### EDIT: simpler reproduction

This fails for me on ubuntu 22.04 and fedora 36 on two separate machines.

```
mkosi -b 1 --verity
```


Discussion:

Resolving patch:
diff --git a/mkosi/__init__.py b/mkosi/__init__.py
--- a/mkosi/__init__.py
+++ b/mkosi/__init__.py
@@ -4177,11 +4177,11 @@ def patch_root_uuid(
     # Use the first 128bit of the root hash as partition UUID of the root partition
     u = uuid.UUID(root_hash[:32])
 
-    with complete_step("Patching root partition UUID…"):
-        part = args.get_partition(PartitionIdentifier.root)
-        assert part is not None
+    part = args.get_partition(PartitionIdentifier.root)
+    assert part is not None
+    part.part_uuid = u
 
-        run(["sfdisk", "--part-uuid", loopdev, str(part.number), str(u)])
+    print('Root partition-type UUID:', u)
 
 
 def extract_partition(


Test patch: