man: document new gpt-auto-generator features

This commit is contained in:
Lennart Poettering
2025-03-20 22:51:04 +01:00
parent e5d2701bc2
commit c481605d0d
2 changed files with 75 additions and 23 deletions

View File

@@ -83,10 +83,14 @@
<listitem><para>Configures the operating system's root filesystem to mount when running in the
initrd. This accepts a device node path (usually <filename>/dev/disk/by-uuid/…</filename> or
<filename>/dev/disk/by-label/…</filename> or similar), or the special values <literal>gpt-auto</literal>,
<literal>fstab</literal>, and <literal>tmpfs</literal>.</para>
<filename>/dev/disk/by-label/…</filename> or similar), or the special values
<literal>gpt-auto</literal>, <literal>gpt-auto-force</literal>, <literal>dissect</literal>,
<literal>dissect-force</literal>, <literal>fstab</literal>, <literal>fstab</literal>, and
<literal>off</literal>.</para>
<para>Use <literal>gpt-auto</literal> to explicitly request automatic root file system discovery via
<para>Set to <literal>gpt-auto</literal>, <literal>gpt-auto-force</literal>,
<literal>dissect</literal>, <literal>dissect-force</literal> to explicitly request automatic root
file system discovery, implemented in
<citerefentry><refentrytitle>systemd-gpt-auto-generator</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
<para>Use <literal>fstab</literal> to explicitly request automatic root file system discovery via
@@ -103,6 +107,11 @@
filesystems (added in v258). Expects an absolute path name referencing an existing directory within the initrd's file
hierarchy to boot into.</para>
<para>Set to <literal>off</literal> to turn off mounting of a root file system.</para>
<para>Note that further <varname>root=</varname> values may be supported, implemented in additional
packages.</para>
<xi:include href="version-info.xml" xpointer="v217"/></listitem>
</varlistentry>
@@ -133,20 +142,18 @@
<varlistentry>
<term><varname>mount.usr=</varname></term>
<listitem><para>Takes the <filename>/usr/</filename> filesystem
to be mounted by the initrd. If
<varname>mount.usrfstype=</varname> or
<varname>mount.usrflags=</varname> is set, then
<varname>mount.usr=</varname> will default to the value set in
<listitem><para>Takes the <filename>/usr/</filename> filesystem to be mounted by the initrd. If
<varname>mount.usrfstype=</varname> or <varname>mount.usrflags=</varname> is set, then the mount
configured via <varname>mount.usr=</varname> will default to the the same value set in
<varname>root=</varname>.</para>
<para>Otherwise, this parameter defaults to the
<filename>/usr/</filename> entry found in
<filename>/etc/fstab</filename> on the root filesystem.</para>
<para>Set to <literal>dissect</literal> to explicitly request automatic <filename>/usr/</filename>
file system discovery, implemented in
<citerefentry><refentrytitle>systemd-gpt-auto-generator</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
<para><varname>mount.usr=</varname> is honored by the initrd.
</para>
<para>Set to <literal>off</literal> to turn off mounting of a separate <filename>/usr/</filename> file system.</para>
<para><varname>mount.usr=</varname> is honored by the initrd.</para>
<xi:include href="version-info.xml" xpointer="v217"/></listitem>
</varlistentry>

View File

@@ -70,11 +70,11 @@
<citerefentry><refentrytitle>systemd-import-generator</refentrytitle><manvolnum>8</manvolnum></citerefentry>
make sure to set the <literal>blockdev</literal> option and set the local name string to
<literal>rootdisk</literal> to achieve this effect. Note that discovery of the root file system on
loopback block devices like this is only done if <literal>root=gpt-auto</literal> is specified
explicitly on the kernel command line, unlike the discovery based on the boot loader reported ESP which
is also enabled if no <literal>root=</literal> parameter is specified at all. (The latter relies on
<command>systemd-udevd.service</command>'s <filename>/dev/gpt-auto-root</filename> block device symlink
generation).</para></listitem>
loopback block devices like this is only done if <literal>root=gpt-auto</literal> or
<literal>root=dissect</literal> is specified explicitly on the kernel command line, unlike the
discovery based on the boot loader reported ESP which is also enabled if no <literal>root=</literal>
parameter is specified at all. (The latter relies on <command>systemd-udevd.service</command>'s
<filename>/dev/gpt-auto-root</filename> block device symlink generation).</para></listitem>
</itemizedlist>
</para>
@@ -317,6 +317,12 @@
and allows enforcing a policy on dissection and use of the automatically discovered GPT partition
table entries.</para>
<para>Note that the specified image policy is not taken into account for automatic root or
<filename>/usr/</filename> file system discovery unless
<varname>root=dissect</varname>/<varname>mount.usr=dissect</varname> (or
<varname>root=dissect-force</varname>) are specified. (The policy will always be applied to the other
auto-discoverable partition types.)</para>
<xi:include href="version-info.xml" xpointer="v254"/></listitem>
</varlistentry>
@@ -328,6 +334,12 @@
and allows enforcing a set of globbing patterns on the partition matching of the automatically
discovered GPT partition table entries.</para>
<para>Note that the specified image filter is not taken into account for automatic root or
<filename>/usr/</filename> file system discovery unless
<varname>root=dissect</varname>/<varname>mount.usr=dissect</varname> (or
<varname>root=dissect-force</varname>) are specified. (The filter will always be applied to the other
auto-discoverable partition types.)</para>
<xi:include href="version-info.xml" xpointer="v258"/></listitem>
</varlistentry>
@@ -337,17 +349,32 @@
<term><varname>rootflags=</varname></term>
<listitem><para>When <varname>root=</varname> is used with the special value
<literal>gpt-auto</literal>, full automatic discovery of the root partition based on the GPT
<literal>gpt-auto</literal>, basic automatic discovery of the root partition based on the GPT
partition type is enabled. Use of the root partition is delayed until factory reset mode is left, in
case it is enabled during the current boot. See <ulink url="https://systemd.io/FACTORY_RESET">Factory
Reset</ulink> for more information on that. If <literal>gpt-auto-force</literal> is specified
automatic discovery of the root partition is enabled, ignoring any factory reset mode. Any other
value disables this logic.</para>
automatic discovery of the root partition is enabled, ignoring any factory reset mode.</para>
<para>If <varname>root=</varname> is set to the special value <literal>dissect</literal> full
automatic discovery of the root partition based on GPT partition information is enabled. This is a
superset of <varname>root=gpt-auto</varname>, as it automatically configures Verity partitions
(including signature-based setup) following the logic defined for that in the <ulink
url="https://uapi-group.org/specifications/specs/discoverable_partitions_specification/">Discoverable
Partitions Specification</ulink>. Moreover it takes the configured image policy and image filter into
account for all partition types, including the root file system. <literal>root=dissect</literal> will
wait for the factory reset phase to be completed if it is in effect before activating the root file
system. Use <literal>root=dissect-force</literal> to ignore the factory reset phase and activate the
root file system immediately.</para>
<para>Any other value (i.e. besides <literal>gpt-auto</literal>, <literal>gpt-auto-force</literal>,
<literal>dissect</literal>, <literal>dissect-force</literal>) disables automatic root file system
discovery.</para>
<para>If <varname>root=</varname> is not specified at all on the kernel command line automatic
discovery of the root partition via the ESP reported by the boot loader is also enabled (taking
factory reset state into account), however in this case discovery based on the loopback block device
<literal>.lo_name</literal> field is not enabled.</para>
factory reset state into account, i.e. equivalent to <literal>root=gpt-auto</literal>), however in
this case discovery based on the loopback block device <literal>.lo_name</literal> field is not
enabled.</para>
<para>The <varname>rootfstype=</varname> and <varname>rootflags=</varname> options are used to select
the file system type and options when the root file system is automatically discovered.</para>
@@ -355,6 +382,24 @@
<xi:include href="version-info.xml" xpointer="v242"/></listitem>
</varlistentry>
<varlistentry>
<term><varname>mount.usr=</varname></term>
<term><varname>mount.usrfstype=</varname></term>
<term><varname>mount.usrflags=</varname></term>
<listitem><para>Similar to <varname>root=</varname>, <varname>rootfstype=</varname>,
<varname>rootflags=</varname> (see above), but applies to the <filename>/usr/</filename> partition
instead. Note that the <literal>gpt-auto</literal>, <literal>gpt-auto-force</literal>,
<literal>dissect-force</literal> settings that <filename>root=</filename> understands are not
supported by <varname>mount.usr=</varname> (however <literal>dissect</literal> is).</para>
<para>Also note that automatic partition discovery for <filename>/usr/</filename> must be enabled
explicitly, unlike the discovery for the root file system, which is enabled if no
<varname>root=</varname> paramater is passed at all.</para>
<xi:include href="version-info.xml" xpointer="v258"/></listitem>
</varlistentry>
<varlistentry>
<term><varname>rw</varname></term>
<term><varname>ro</varname></term>