[systemd-devel] Issues with /usr GPT auto-mount

Lennart Poettering lennart at poettering.net
Thu Jul 14 12:38:39 UTC 2022


On Do, 14.07.22 12:08, Michael Cassaniti (michael at cassaniti.id.au) wrote:

> Hi,
>
> I've read the below two articles and potentially made wrong assumptions
> about how automatic discovery of GPT partitions works for EFI boot rather
> than from systemd-nspawn.
>
> https://0pointer.net/blog/the-wondrous-world-of-discoverable-gpt-disk-images.html
> (particularly the Versioning + Multi-Arch section)
> https://0pointer.net/blog/fitting-everything-together.html
>
> After reading this on top of the gpt-auto-generator.c code (read doesn't
> mean perfectly understood) I believe that only the root file system gets
> mounted under an EFI boot. I was hoping that both root and /usr get mounted
> as appropriate. I can confirm when using 'systemd-dissect /dev/sda' that
> there is a designated /usr partition with a label that isn't '_empty' and
> for the correct architecture.
>
> Either I've done something wrong and need help or systemd-gpt-auto-generator
> is working correctly and I'm wrong. All feedback is appreciated.

This functionality is still missing in systemd-gpt-generator
currently. Would love to review/merge a patch that fills in the gap.

(In my own usecase I always used usrhash= on the kernel cmdline, to
pin a specific /usr/ fs to a specific kernel, thus /usr/ auto
discovery was never needed, but we should definitely support that too)

Lennart

--
Lennart Poettering, Berlin


More information about the systemd-devel mailing list