Debian Codegraph @

man/systemd-sysext.xml

raw
1 <?xml version='1.0'?> <!--*-nxml-*-->
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
4 <!-- SPDX-License-Identifier: LGPL-2.1-or-later -->
5
6 <refentry id="systemd-sysext" conditional='ENABLE_SYSEXT'
7 xmlns:xi="http://www.w3.org/2001/XInclude">
8
9 <refentryinfo>
10 <title>systemd-sysext</title>
11 <productname>systemd</productname>
12 </refentryinfo>
13
14 <refmeta>
15 <refentrytitle>systemd-sysext</refentrytitle>
16 <manvolnum>8</manvolnum>
17 </refmeta>
18
19 <refnamediv>
20 <refname>systemd-sysext</refname>
21 <refname>systemd-sysext.service</refname>
22 <refname>systemd-sysext-initrd.service</refname>
23 <refname>systemd-sysext-sysroot.service</refname>
24 <refname>systemd-confext</refname>
25 <refname>systemd-confext.service</refname>
26 <refname>systemd-confext-initrd.service</refname>
27 <refname>systemd-confext-sysroot.service</refname>
28 <refpurpose>Activates System Extension Images</refpurpose>
29 </refnamediv>
30
31 <refsynopsisdiv>
32 <cmdsynopsis>
33 <command>systemd-sysext</command>
34 <arg choice="opt" rep="repeat">OPTIONS</arg>
35 <arg choice="plain">COMMAND</arg>
36 </cmdsynopsis>
37
38 <para><filename>systemd-sysext.service</filename></para>
39
40 <cmdsynopsis>
41 <command>systemd-confext</command>
42 <arg choice="opt" rep="repeat">OPTIONS</arg>
43 <arg choice="plain">COMMAND</arg>
44 </cmdsynopsis>
45
46 <para><filename>systemd-confext.service</filename></para>
47 </refsynopsisdiv>
48
49 <refsect1>
50 <title>Description</title>
51
52 <para><command>systemd-sysext</command> activates/deactivates system extension images. System extension
53 images may – dynamically at runtime — extend the <filename>/usr/</filename> and
54 <filename>/opt/</filename> directory hierarchies with additional files. This is particularly useful on
55 immutable system images where a <filename>/usr/</filename> and/or <filename>/opt/</filename> hierarchy
56 residing on a read-only file system shall be extended temporarily at runtime without making any
57 persistent modifications.</para>
58
59 <para>System extension images should contain files and directories similar in fashion to regular
60 operating system tree. When one or more system extension images are activated, their
61 <filename>/usr/</filename> and <filename>/opt/</filename> hierarchies are combined via
62 <literal>overlayfs</literal> with the same hierarchies of the host OS, and the host
63 <filename>/usr/</filename> and <filename>/opt/</filename> overmounted with it ("merging"). When they are
64 deactivated, the mount point is disassembled — again revealing the unmodified original host version of
65 the hierarchy ("unmerging"). Merging thus makes the extension's resources suddenly appear below the
66 <filename>/usr/</filename> and <filename>/opt/</filename> hierarchies as if they were included in the
67 base OS image itself. Unmerging makes them disappear again, leaving in place only the files that were
68 shipped with the base OS image itself.</para>
69
70 <para>Files and directories contained in the extension images outside of the <filename>/usr/</filename>
71 and <filename>/opt/</filename> hierarchies are <emphasis>not</emphasis> merged, and hence have no effect
72 when included in a system extension image. In particular, files in the <filename>/etc/</filename> and
73 <filename>/var/</filename> included in a system extension image will <emphasis>not</emphasis> appear in
74 the respective hierarchies after activation.</para>
75
76 <para>System extension images are strictly read-only by default. On mutable host file systems,
77 <filename>/usr/</filename> and <filename>/opt/</filename> hierarchies become read-only while extensions
78 are merged, unless mutability is enabled. Mutability may be enabled via the <option>--mutable=</option>
79 option and the <varname>Mutable=</varname> option in the configuration file;
80 see "Mutability" below for more information.</para>
81
82 <para>Various command options can be configured globally via configuration files. See
83 <citerefentry><refentrytitle>sysext.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>
84 for details.</para>
85
86 <para>System extensions are supposed to be purely additive, i.e. they are supposed to include only files
87 that do not exist in the underlying basic OS image. However, the underlying mechanism (overlayfs) also
88 allows overlaying or removing files, but it is recommended not to make use of this.</para>
89
90 <para>System extension images may be provided in the following formats:</para>
91
92 <orderedlist>
93 <listitem><para>Plain directories or btrfs subvolumes containing the OS tree</para></listitem>
94 <listitem><para>Disk images with a GPT disk label, following the <ulink
95 url="https://uapi-group.org/specifications/specs/discoverable_partitions_specification">UAPI.2 Discoverable Partitions Specification</ulink></para></listitem>
96 <listitem><para>Disk images lacking a partition table, with a naked Linux file system (e.g. erofs,
97 squashfs or ext4)</para></listitem>
98 </orderedlist>
99
100 <para>These image formats are the same ones that
101 <citerefentry><refentrytitle>systemd-nspawn</refentrytitle><manvolnum>1</manvolnum></citerefentry>
102 supports via its <option>--directory=</option>/<option>--image=</option> switches and those that the
103 service manager supports via <option>RootDirectory=</option>/<option>RootImage=</option>. Similar to
104 them they may optionally carry Verity authentication information.</para>
105
106 <para>System extensions are searched for in the directories
107 <filename>/etc/extensions/</filename>, <filename>/run/extensions/</filename> and
108 <filename>/var/lib/extensions/</filename>. The first two listed directories are not suitable for
109 carrying large binary images, however are still useful for carrying symlinks to them. The primary place
110 for installing system extensions is <filename>/var/lib/extensions/</filename>. Any directories found in
111 these search directories are considered directory based extension images; any files with the
112 <filename>.raw</filename> suffix are considered disk image based extension images. When invoked in the
113 initrd, the additional directory <filename>/.extra/sysext/</filename> is included in the directories that
114 are searched for extension images. Note however, that by default a tighter image policy applies to images
115 found there, though, see below. This directory is populated by
116 <citerefentry><refentrytitle>systemd-stub</refentrytitle><manvolnum>7</manvolnum></citerefentry> with
117 extension images found in the system's EFI System Partition.</para>
118
119 <para>During boot, system and configuration extension images are activated automatically if the
120 <filename>systemd-sysext.service</filename> and <filename>systemd-confext.service</filename> services are
121 enabled. Note that these services run only after the underlying file systems where system and configuration
122 extensions may be located have been mounted. To make it possible to ship resources that are processed by
123 subsystems running in the earliest boot stages (for example, system services or
124 <citerefentry><refentrytitle>systemd-sysusers</refentrytitle><manvolnum>8</manvolnum></citerefentry>
125 definitions), the <filename>systemd-sysext-sysroot.service</filename> and
126 <filename>systemd-confext-sysroot.service</filename> initrd services are provided. Currently, these
127 services cannot be used to merge system extensions from <filename>/sysroot/var/lib/extensions/</filename>
128 and configuration extensions from <filename>/sysroot/var/lib/confexts/</filename> when the
129 <filename>/var/</filename> partition is split off. These extensions are later merged by the
130 <filename>systemd-sysext.service</filename> and <filename>systemd-confext.service</filename> services
131 during the main OS boot process.</para>
132
133 <para>Also, see the <ulink url="https://systemd.io/PORTABLE_SERVICES">Portable Services</ulink>
134 page for a simple mechanism for shipping system services in disk images, in a similar fashion to OS
135 extensions. Note the differences in isolation between these two mechanisms: while system extensions directly extend
136 the underlying OS image with additional files that appear as if they were shipped in the OS image itself
137 and thus imply no security isolation, portable services imply service-level sandboxing in one way or another.</para>
138
139 <para>The <filename>systemd-sysext.service</filename> and <filename>systemd-confext.service</filename>
140 services are guaranteed to finish start-up before <filename>basic.target</filename> is reached; i.e., by the time
141 regular services initialize (those which do not use <varname>DefaultDependencies=no</varname>), the files
142 and directories provided by system and configuration extensions are available in <filename>/usr/</filename>,
143 <filename>/opt/</filename>, and <filename>/etc/</filename> and may be accessed.</para>
144
145 <para>System and configuration extensions can also be used to extend the initrd, and the
146 <filename>systemd-sysext-initrd.service</filename> and <filename>systemd-confext-initrd.service</filename>
147 initrd services are provided. Note that some limitations apply: resources that are used in the earliest boot
148 stages of the initrd (e.g. system services) cannot be updated.</para>
149
150 <para>Note that there is no concept of enabling/disabling installed system extension images: all
151 installed extension images are automatically activated at boot. However, you can place an empty directory
152 named like the extension (no <filename>.raw</filename>) in <filename>/etc/extensions/</filename> to "mask"
153 an extension with the same name in a system folder with lower precedence. It is also possible to disable
154 automatic merging altogether using the <varname>rd.systemd.sysext=</varname>, <varname>rd.systemd.confext=</varname>,
155 <varname>systemd.sysext=</varname>, and <varname>systemd.confext=</varname> kernel command line options.
156 Note that <filename>systemd-sysext-sysroot.service</filename> and
157 <filename>systemd-confext-sysroot.service</filename> are controlled by the <varname>systemd.sysext=</varname>
158 and <varname>systemd.confext=</varname> options, as these services merge system and configuration
159 extensions for the main system, not for the initrd.</para>
160
161 <para>A simple mechanism for version compatibility is enforced: a system extension image must carry a
162 <filename>/usr/lib/extension-release.d/extension-release.<replaceable>NAME</replaceable></filename>
163 file, which must match its image name, that is compared with the host <filename>os-release</filename>
164 file: the contained <varname>ID=</varname> fields have to match unless <literal>_any</literal> is set
165 for the extension. If the extension <varname>ID=</varname> is not <literal>_any</literal>, the
166 <varname>SYSEXT_LEVEL=</varname> field (if defined) has to match. If the latter is not defined, the
167 <varname>VERSION_ID=</varname> field has to match instead. If the extension defines the
168 <varname>ARCHITECTURE=</varname> field and the value is not <literal>_any</literal> it has to match the kernel's
169 architecture reported by <citerefentry><refentrytitle>uname</refentrytitle><manvolnum>2</manvolnum></citerefentry>
170 but the used architecture identifiers are the same as for <varname>ConditionArchitecture=</varname>
171 described in <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
172 <varname>EXTENSION_RELOAD_MANAGER=</varname> can be set to 1 if the extension requires a service manager reload after application
173 of the extension. Note that for the reasons mentioned earlier,
174 <ulink url="https://systemd.io/PORTABLE_SERVICES">Portable Services</ulink> remain
175 the recommended way to ship system services.
176
177 System extensions should not ship a <filename>/usr/lib/os-release</filename> file (as that would be merged
178 into the host <filename>/usr/</filename> tree, overriding the host OS version data, which is not desirable).
179 The <filename>extension-release</filename> file follows the same format and semantics, and carries the same
180 content, as the <filename>os-release</filename> file of the OS, but it describes the resources carried
181 in the extension image.</para>
182
183 <para>The <command>systemd-confext</command> concept follows the same principle as the
184 <citerefentry><refentrytitle>systemd-sysext</refentrytitle><manvolnum>8</manvolnum></citerefentry>
185 functionality but instead of working on <filename>/usr</filename> and <filename>/opt</filename>,
186 <command>confext</command> will extend only <filename>/etc</filename>. Files and directories contained
187 in the confext images outside of the <filename>/etc/</filename> hierarchy are <emphasis>not</emphasis>
188 merged, and hence have no effect when included in the image. Formats for these images are of the
189 same as sysext images. The merged hierarchy will be mounted with <literal>nosuid</literal> and
190 (if not disabled via <option>--noexec=false</option>) <literal>noexec</literal>.</para>
191
192 <para>Just like sysexts, confexts are strictly read-only by default. Merging confexts on mutable host
193 file systems will result in <filename>/etc/</filename> becoming read-only. As with sysexts, mutability
194 can be enabled via the <option>--mutable=</option> option. Refer to "Mutability" below for more
195 information.</para>
196
197 <para>Confexts are looked for in the directories <filename>/run/confexts/</filename>,
198 <filename>/var/lib/confexts/</filename>, <filename>/usr/lib/confexts/</filename> and
199 <filename>/usr/local/lib/confexts/</filename>. The first listed directory is not suitable for
200 carrying large binary images, however is still useful for carrying symlinks to them. The primary place
201 for installing configuration extensions is <filename>/var/lib/confexts/</filename>. Any directories found
202 in these search directories are considered directory based confext images; any files with the
203 <filename>.raw</filename> suffix are considered disk image based confext images.</para>
204
205 <para>Again, just like sysext images, the confext images will contain a
206 <filename>/etc/extension-release.d/extension-release.<replaceable>NAME</replaceable></filename>
207 file, which must match the image name (with the usual escape hatch of
208 the <varname>user.extension-release.strict</varname>
209 <citerefentry project='man-pages'><refentrytitle>xattr</refentrytitle><manvolnum>7</manvolnum></citerefentry>),
210 and again with content being one or more of <varname>ID=</varname>, <varname>VERSION_ID=</varname>, and
211 <varname>CONFEXT_LEVEL</varname>. Confext images will then be checked and matched against the base OS
212 layer.</para>
213 </refsect1>
214
215 <refsect1>
216 <title>Uses</title>
217
218 <para>The primary use case for system images are immutable environments where debugging and development
219 tools shall optionally be made available, but not included in the immutable base OS image itself (e.g.
220 <citerefentry project='man-pages'><refentrytitle>strace</refentrytitle><manvolnum>1</manvolnum></citerefentry>
221 and
222 <citerefentry project='man-pages'><refentrytitle>gdb</refentrytitle><manvolnum>1</manvolnum></citerefentry>
223 shall be an optionally installable addition in order to make debugging/development easier). System
224 extension images should not be misunderstood as a generic software packaging framework, as no dependency
225 scheme is available: system extensions should carry all files they need themselves, except for those
226 already shipped in the underlying host system image. Typically, system extension images are built at the
227 same time as the base OS image — within the same build system.</para>
228
229 <para>Another use case for the system extension concept is temporarily overriding OS supplied resources
230 with newer ones, for example to install a locally compiled development version of some low-level
231 component over the immutable OS image without doing a full OS rebuild or modifying the nominally
232 immutable image. (e.g. "install" a locally built package with <command>DESTDIR=/var/lib/extensions/mytest
233 make install &amp;&amp; systemd-sysext refresh</command>, making it available in
234 <filename>/usr/</filename> as if it was installed in the OS image itself.) This case works regardless of
235 whether the underlying host <filename>/usr/</filename> is managed as immutable disk image or is a traditional
236 package manager controlled (i.e. writable) tree.</para>
237
238 <para>With <command>systemd-confext</command> one can perform runtime reconfiguration of OS services.
239 Sometimes, there is a need to swap certain configuration parameter values or restart only a specific
240 service without deployment of new code or a complete OS deployment. In other words, we want to be able
241 to tie the most frequently configured options to runtime updateable flags that can be changed without a
242 system reboot. This will help reduce servicing times when there is a need for changing the OS configuration.
243 It also provides a reliable tool for managing configuration because all old configuration files disappear when
244 the <command>systemd-confext</command> image is removed.</para></refsect1>
245
246 <refsect1>
247 <title>Mutability</title>
248 <para>By default, merging system extensions on mutable host file systems will render <filename>/usr/</filename>
249 and <filename>/opt/</filename> hierarchies read-only. Merging configuration extensions will have the same
250 effect on <filename>/etc/</filename>. Mutable mode allows writes to these locations when extensions are
251 merged.</para>
252
253 <para>The following modes are supported:
254 <orderedlist>
255 <listitem><para><option>disabled</option>: Force immutable mode even if write routing directories exist
256 below <filename>/var/lib/extensions.mutable/</filename>. This is the default.</para></listitem>
257 <listitem><para><option>auto</option>: Automatic mode. Mutability is disabled by default and only
258 enabled if a corresponding write routing directory exists below
259 <filename>/var/lib/extensions.mutable/</filename>.</para></listitem>
260 <listitem><para><option>enabled</option>: Force mutable mode and automatically create write routing
261 directories below <filename>/var/lib/extensions.mutable/</filename> when required.</para></listitem>
262 <listitem><para><option>import</option>: Force immutable mode like <option>disabled</option> above, but
263 merge the contents of directories below <filename>/var/lib/extensions.mutable/</filename> into the host
264 file system.</para></listitem>
265 <listitem><para><option>ephemeral</option>: Force mutable mode like <option>enabled</option> above, but
266 instead of using write routing directory below <filename>/var/lib/extensions.mutable/</filename>,
267 <command>systemd-sysext</command> will use empty ephemeral directories. This means that the
268 modifications made in the merged hierarchies will be gone when the hierarchies are
269 unmerged.</para></listitem>
270 <listitem><para><option>ephemeral-import</option>: Force mutable mode like <option>ephemeral</option>
271 above, but instead of ignoring the contents of write routing directories under
272 <filename>/var/lib/extensions.mutable/</filename>, merge them into the host file system, like
273 <option>import</option> does.</para></listitem>
274 </orderedlist>
275 See "Options" below on specifying modes using the <option>--mutable=</option> command line option.</para>
276
277 <para>With exception of the ephemeral mode, the mutable mode routes writes to subdirectories in
278 <filename>/var/lib/extensions.mutable/</filename>.
279 <simplelist type="horiz">
280 <member>Writes to <filename>/usr/</filename> are directed to <filename>/var/lib/extensions.mutable/usr/</filename></member>,
281 <member>writes to <filename>/opt/</filename> are directed to <filename>/var/lib/extensions.mutable/opt/</filename>, and</member>
282 <member>writes to <filename>/etc/</filename> land in <filename>/var/lib/extensions.mutable/etc/</filename>.</member>
283 </simplelist></para>
284
285 <para>If <filename>usr/</filename>, <filename>opt/</filename>, or <filename>etc/</filename>
286 in <filename>/var/lib/extensions.mutable/</filename> are symlinks, then writes are directed to the
287 symlinks' targets.
288 Consequently, to retain mutability of a host file system, create symlinks
289 <simplelist type="horiz">
290 <member><filename>/var/lib/extensions.mutable/etc/</filename> → <filename>/etc/</filename></member>
291 <member><filename>/var/lib/extensions.mutable/usr/</filename> → <filename>/usr/</filename></member>
292 <member><filename>/var/lib/extensions.mutable/opt/</filename> → <filename>/opt/</filename></member>
293 </simplelist>
294 to route writes back to the original base directory hierarchy.</para>
295
296 <para>Alternatively, a temporary file system may be mounted to
297 <filename>/var/lib/extensions.mutable/</filename>, or symlinks in
298 <filename>/var/lib/extensions.mutable/</filename> may point to sub-directories on a temporary file system
299 (e.g. below <filename>/tmp/</filename>) to only allow ephemeral changes. Note that this is not the same
300 as ephemeral mode, because the temporary file system will still exist after unmerging.</para>
301
302 <xi:include href="version-info.xml" xpointer="v256"/>
303 </refsect1>
304
305 <refsect1>
306 <title>Commands</title>
307
308 <para>The following commands are understood by both the sysext and confext concepts:</para>
309
310 <variablelist>
311 <varlistentry>
312 <term><option>status</option></term>
313
314 <listitem><para>When invoked without any command verb, or when <option>status</option> is specified
315 the current merge status is shown, separately (for both <filename>/usr/</filename> and
316 <filename>/opt/</filename> of sysext and for <filename>/etc/</filename> of confext).</para>
317
318 <xi:include href="version-info.xml" xpointer="v248"/></listitem>
319 </varlistentry>
320
321 <varlistentry>
322 <term><option>merge</option></term>
323 <listitem><para>Merges all currently installed system extension images into
324 <filename>/usr/</filename> and <filename>/opt/</filename>, by overmounting these hierarchies with an
325 <literal>overlayfs</literal> file system combining the underlying hierarchies with those included in
326 the extension images. This command will fail if the hierarchies are already merged. For confext, the merge
327 happens into the <filename>/etc/</filename> directory instead.</para>
328
329 <xi:include href="version-info.xml" xpointer="v248"/></listitem>
330 </varlistentry>
331
332 <varlistentry>
333 <term><option>unmerge</option></term>
334 <listitem><para>Unmerges all currently installed system extension images from
335 <filename>/usr/</filename> and <filename>/opt/</filename> for sysext and <filename>/etc/</filename>,
336 for confext, by unmounting the <literal>overlayfs</literal> file systems created by <option>merge</option>
337 prior.</para>
338
339 <xi:include href="version-info.xml" xpointer="v248"/></listitem>
340 </varlistentry>
341
342 <varlistentry>
343 <term><option>refresh</option></term>
344 <listitem><para>A combination of <option>unmerge</option> and <option>merge</option>: if already
345 mounted the existing <literal>overlayfs</literal> instance is unmounted temporarily, and then
346 replaced by a new version. This command is useful after installing/removing system extension images,
347 in order to update the <literal>overlayfs</literal> file system accordingly. If no system extensions
348 are installed when this command is executed, the equivalent of <option>unmerge</option> is executed,
349 without establishing any new <literal>overlayfs</literal> instance.
350 Note that currently there's a brief moment where neither the old nor the new <literal>overlayfs</literal>
351 file system is mounted. This implies that all resources supplied by a system extension will briefly
352 disappear — even if it exists continuously during the refresh operation.</para>
353
354 <xi:include href="version-info.xml" xpointer="v248"/></listitem>
355 </varlistentry>
356
357 <varlistentry>
358 <term><option>list</option></term>
359
360 <listitem><para>A brief list of installed extension images is shown.</para>
361
362 <xi:include href="version-info.xml" xpointer="v248"/></listitem>
363 </varlistentry>
364
365 <xi:include href="standard-options.xml" xpointer="help" />
366 <xi:include href="standard-options.xml" xpointer="version" />
367 </variablelist>
368 </refsect1>
369
370 <refsect1>
371 <title>Options</title>
372
373 <variablelist>
374 <varlistentry>
375 <term><option>--root=</option></term>
376
377 <listitem><para>Operate relative to the specified root directory, i.e. establish the
378 <literal>overlayfs</literal> mount not on the top-level host <filename>/usr/</filename> and
379 <filename>/opt/</filename> hierarchies for sysext or <filename>/etc/</filename> for confext,
380 but below some specified root directory.</para>
381
382 <xi:include href="version-info.xml" xpointer="v248"/></listitem>
383 </varlistentry>
384
385 <varlistentry>
386 <term><option>--force</option></term>
387
388 <listitem><para>When merging system extensions into <filename>/usr/</filename> and
389 <filename>/opt/</filename> for sysext and <filename>/etc/</filename> for confext,
390 ignore version incompatibilities, i.e. force merging regardless of
391 whether the version information included in the images matches the host or not.</para>
392
393 <xi:include href="version-info.xml" xpointer="v248"/></listitem>
394 </varlistentry>
395
396 <varlistentry>
397 <term><option>--always-refresh=yes|no</option></term>
398
399 <listitem><para>When refreshing system extensions on <filename>/usr/</filename> and <filename>/opt/</filename>
400 for sysext and <filename>/etc/</filename> for confext, ignore when the existing merged extensions
401 already match what would be merged.
402 By default the refresh is skipped when no changes are found. Note that changes done to an extension
403 directory while it's merged are ignored without this flag (unless another extension got changed).
404 Note that changing the contents while merged is also undefined behavior in overlayfs.</para>
405
406 <xi:include href="version-info.xml" xpointer="v260"/></listitem>
407 </varlistentry>
408
409 <varlistentry>
410 <term><option>--image-policy=<replaceable>policy</replaceable></option></term>
411
412 <listitem><para>Takes an image policy string as argument, as per
413 <citerefentry><refentrytitle>systemd.image-policy</refentrytitle><manvolnum>7</manvolnum></citerefentry>. The
414 policy is enforced when operating on system extension disk images. If not specified, defaults to
415 <literal>root=verity+signed+encrypted+unprotected+absent:usr=verity+signed+encrypted+unprotected+absent</literal>
416 for system extensions, i.e. only the root and <filename>/usr/</filename> file systems in the image
417 are used. For configuration extensions defaults to
418 <literal>root=verity+signed+encrypted+unprotected+absent</literal>. When run in the initrd and
419 operating on a system extension image stored in the <filename>/.extra/sysext/</filename> directory a
420 slightly stricter policy is used by default: <literal>root=signed+absent:usr=signed+absent</literal>,
421 see above for details.</para>
422
423 <xi:include href="version-info.xml" xpointer="v254"/></listitem>
424 </varlistentry>
425
426 <varlistentry>
427 <term><option>--mutable=<replaceable>BOOL</replaceable>|<replaceable>auto</replaceable>|<replaceable>import</replaceable>|<replaceable>ephemeral</replaceable>|<replaceable>ephemeral-import</replaceable>|<replaceable>help</replaceable></option></term>
428 <listitem><para>Set mutable mode. The special value <literal>help</literal> will list the known values.</para>
429
430 <variablelist>
431 <varlistentry>
432 <term><option>no</option></term>
433 <listitem><para>force immutable mode even with write routing directories present.
434 This is the default.</para>
435 <xi:include href="version-info.xml" xpointer="v256"/></listitem>
436 </varlistentry>
437
438 <varlistentry>
439 <term><option>auto</option></term>
440 <listitem><para>enable mutable mode individually for <filename>/usr/</filename>,
441 <filename>/opt/</filename>, and <filename>/etc/</filename> if write routing sub-directories
442 or symlinks are present in <filename>/var/lib/extensions.mutable/</filename>; disable otherwise.
443 See "Mutability" above for more information on write routing.</para>
444 <xi:include href="version-info.xml" xpointer="v256"/></listitem>
445 </varlistentry>
446
447 <varlistentry>
448 <term><option>yes</option></term>
449 <listitem><para>force mutable mode. Write routing directories will be created in
450 <filename>/var/lib/extensions.mutable/</filename> if not present.</para>
451 <xi:include href="version-info.xml" xpointer="v256"/></listitem>
452 </varlistentry>
453
454 <varlistentry>
455 <term><option>import</option></term>
456 <listitem><para>immutable mode, but with contents of write routing directories in
457 <filename>/var/lib/extensions.mutable/</filename> also merged into the host file system.</para>
458 <xi:include href="version-info.xml" xpointer="v256"/></listitem>
459 </varlistentry>
460
461 <varlistentry>
462 <term><option>ephemeral</option></term>
463 <listitem><para>force mutable mode, but with contents of write routing directories in
464 <filename>/var/lib/extensions.mutable/</filename> being ignored, and modifications of the host
465 file system being discarded after unmerge.</para>
466 <xi:include href="version-info.xml" xpointer="v256"/></listitem>
467 </varlistentry>
468
469 <varlistentry>
470 <term><option>ephemeral-import</option></term>
471 <listitem><para>force mutable mode, with contents of write routing directories in
472 <filename>/var/lib/extensions.mutable/</filename> being merged into the host file system, but
473 with the modifications made to the host file system being discarded after unmerge.</para>
474 <xi:include href="version-info.xml" xpointer="v256"/></listitem>
475 </varlistentry>
476
477 <varlistentry>
478 <term><option>help</option></term>
479 <listitem><para>list known values and exit immediately.</para>
480 <xi:include href="version-info.xml" xpointer="v259"/></listitem>
481 </varlistentry>
482 </variablelist>
483
484 <xi:include href="version-info.xml" xpointer="v256"/></listitem>
485 </varlistentry>
486
487 <varlistentry>
488 <term><option>--noexec=<replaceable>BOOL</replaceable></option></term>
489
490 <listitem><para>When merging configuration extensions into <filename>/etc/</filename> the
491 <literal>MS_NOEXEC</literal> mount flag is used by default. This option can be used to disable
492 it.</para>
493
494 <xi:include href="version-info.xml" xpointer="v254"/></listitem>
495 </varlistentry>
496
497 <varlistentry>
498 <term><option>--no-reload</option></term>
499
500 <listitem>
501 <para>When used with <command>merge</command>,
502 <command>unmerge</command> or <command>refresh</command>, do not reload daemon
503 after executing the changes even if an extension that is applied requires a reload via the
504 <varname>EXTENSION_RELOAD_MANAGER=</varname> set to 1.</para>
505
506 <xi:include href="version-info.xml" xpointer="v255"/>
507 </listitem>
508 </varlistentry>
509
510 <xi:include href="standard-options.xml" xpointer="no-pager" />
511 <xi:include href="standard-options.xml" xpointer="no-legend" />
512 <xi:include href="standard-options.xml" xpointer="json" />
513 </variablelist>
514 </refsect1>
515
516 <refsect1>
517 <title>Exit status</title>
518
519 <para>On success, 0 is returned.</para>
520 </refsect1>
521
522 <refsect1>
523 <title>See Also</title>
524 <para><simplelist type="inline">
525 <member><citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry></member>
526 <member><citerefentry><refentrytitle>sysext.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
527 <member><citerefentry><refentrytitle>systemd-nspawn</refentrytitle><manvolnum>1</manvolnum></citerefentry></member>
528 <member><citerefentry><refentrytitle>systemd-stub</refentrytitle><manvolnum>7</manvolnum></citerefentry></member>
529 <member><citerefentry><refentrytitle>importctl</refentrytitle><manvolnum>1</manvolnum></citerefentry></member>
530 </simplelist></para>
531 </refsect1>
532
533 </refentry>