summaryrefslogtreecommitdiffstats
path: root/man/systemd.unit.xml
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-12 03:50:42 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-12 03:50:42 +0000
commit78e9bb837c258ac0ec7712b3d612cc2f407e731e (patch)
treef515d16b6efd858a9aeb5b0ef5d6f90bf288283d /man/systemd.unit.xml
parentAdding debian version 255.5-1. (diff)
downloadsystemd-78e9bb837c258ac0ec7712b3d612cc2f407e731e.tar.xz
systemd-78e9bb837c258ac0ec7712b3d612cc2f407e731e.zip
Merging upstream version 256.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'man/systemd.unit.xml')
-rw-r--r--man/systemd.unit.xml182
1 files changed, 109 insertions, 73 deletions
diff --git a/man/systemd.unit.xml b/man/systemd.unit.xml
index 301fe77..919e641 100644
--- a/man/systemd.unit.xml
+++ b/man/systemd.unit.xml
@@ -1,6 +1,6 @@
<?xml version='1.0'?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
- "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" [
+ "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
<!ENTITY % entities SYSTEM "custom-entities.ent" >
%entities;
]>
@@ -25,52 +25,60 @@
</refnamediv>
<refsynopsisdiv>
- <para><filename><replaceable>service</replaceable>.service</filename>,
- <filename><replaceable>socket</replaceable>.socket</filename>,
- <filename><replaceable>device</replaceable>.device</filename>,
- <filename><replaceable>mount</replaceable>.mount</filename>,
- <filename><replaceable>automount</replaceable>.automount</filename>,
- <filename><replaceable>swap</replaceable>.swap</filename>,
- <filename><replaceable>target</replaceable>.target</filename>,
- <filename><replaceable>path</replaceable>.path</filename>,
- <filename><replaceable>timer</replaceable>.timer</filename>,
- <filename><replaceable>slice</replaceable>.slice</filename>,
- <filename><replaceable>scope</replaceable>.scope</filename></para>
+ <para><simplelist type="inline">
+ <member><filename><replaceable>service</replaceable>.service</filename></member>
+ <member><filename><replaceable>socket</replaceable>.socket</filename></member>
+ <member><filename><replaceable>device</replaceable>.device</filename></member>
+ <member><filename><replaceable>mount</replaceable>.mount</filename></member>
+ <member><filename><replaceable>automount</replaceable>.automount</filename></member>
+ <member><filename><replaceable>swap</replaceable>.swap</filename></member>
+ <member><filename><replaceable>target</replaceable>.target</filename></member>
+ <member><filename><replaceable>path</replaceable>.path</filename></member>
+ <member><filename><replaceable>timer</replaceable>.timer</filename></member>
+ <member><filename><replaceable>slice</replaceable>.slice</filename></member>
+ <member><filename><replaceable>scope</replaceable>.scope</filename></member>
+ </simplelist></para>
<refsect2>
<title>System Unit Search Path</title>
- <para><literallayout><filename>/etc/systemd/system.control/*</filename>
-<filename>/run/systemd/system.control/*</filename>
-<filename>/run/systemd/transient/*</filename>
-<filename>/run/systemd/generator.early/*</filename>
-<filename>/etc/systemd/system/*</filename>
-<filename>/etc/systemd/system.attached/*</filename>
-<filename>/run/systemd/system/*</filename>
-<filename>/run/systemd/system.attached/*</filename>
-<filename>/run/systemd/generator/*</filename>
-<filename index='false'>…</filename>
-<filename>/usr/lib/systemd/system/*</filename>
-<filename>/run/systemd/generator.late/*</filename></literallayout></para>
+ <para><simplelist>
+ <member><filename>/etc/systemd/system.control/*</filename></member>
+ <member><filename>/run/systemd/system.control/*</filename></member>
+ <member><filename>/run/systemd/transient/*</filename></member>
+ <member><filename>/run/systemd/generator.early/*</filename></member>
+ <member><filename>/etc/systemd/system/*</filename></member>
+ <member><filename>/etc/systemd/system.attached/*</filename></member>
+ <member><filename>/run/systemd/system/*</filename></member>
+ <member><filename>/run/systemd/system.attached/*</filename></member>
+ <member><filename>/run/systemd/generator/*</filename></member>
+ <member><filename index='false'>…</filename></member>
+ <member><filename>/usr/local/lib/systemd/system/*</filename></member>
+ <member><filename>/usr/lib/systemd/system/*</filename></member>
+ <member><filename>/run/systemd/generator.late/*</filename></member>
+ </simplelist></para>
</refsect2>
<refsect2>
<title>User Unit Search Path</title>
- <para><literallayout><filename>~/.config/systemd/user.control/*</filename>
-<filename>$XDG_RUNTIME_DIR/systemd/user.control/*</filename>
-<filename>$XDG_RUNTIME_DIR/systemd/transient/*</filename>
-<filename>$XDG_RUNTIME_DIR/systemd/generator.early/*</filename>
-<filename>~/.config/systemd/user/*</filename>
-<filename>$XDG_CONFIG_DIRS/systemd/user/*</filename>
-<filename>/etc/systemd/user/*</filename>
-<filename>$XDG_RUNTIME_DIR/systemd/user/*</filename>
-<filename>/run/systemd/user/*</filename>
-<filename>$XDG_RUNTIME_DIR/systemd/generator/*</filename>
-<filename>$XDG_DATA_HOME/systemd/user/*</filename>
-<filename>$XDG_DATA_DIRS/systemd/user/*</filename>
-<filename index='false'>…</filename>
-<filename>/usr/lib/systemd/user/*</filename>
-<filename>$XDG_RUNTIME_DIR/systemd/generator.late/*</filename></literallayout></para>
+ <para><simplelist>
+ <member><filename>~/.config/systemd/user.control/*</filename></member>
+ <member><filename>$XDG_RUNTIME_DIR/systemd/user.control/*</filename></member>
+ <member><filename>$XDG_RUNTIME_DIR/systemd/transient/*</filename></member>
+ <member><filename>$XDG_RUNTIME_DIR/systemd/generator.early/*</filename></member>
+ <member><filename>~/.config/systemd/user/*</filename></member>
+ <member><filename>$XDG_CONFIG_DIRS/systemd/user/*</filename></member>
+ <member><filename>/etc/systemd/user/*</filename></member>
+ <member><filename>$XDG_RUNTIME_DIR/systemd/user/*</filename></member>
+ <member><filename>/run/systemd/user/*</filename></member>
+ <member><filename>$XDG_RUNTIME_DIR/systemd/generator/*</filename></member>
+ <member><filename>$XDG_DATA_HOME/systemd/user/*</filename></member>
+ <member><filename>$XDG_DATA_DIRS/systemd/user/*</filename></member>
+ <member><filename index='false'>…</filename></member>
+ <member><filename>/usr/local/lib/systemd/user/*</filename></member>
+ <member><filename>/usr/lib/systemd/user/*</filename></member>
+ <member><filename>$XDG_RUNTIME_DIR/systemd/generator.late/*</filename></member>
+ </simplelist></para>
</refsect2>
</refsynopsisdiv>
@@ -158,7 +166,7 @@
instance (if any) is always uniquely defined for a given unit and all its aliases. The target of alias
symlink must point to a valid unit file location, i.e. the symlink target name must match the symlink
source name as described, and the destination path must be in one of the unit search paths, see UNIT FILE
- LOAD PATH section below for more details. Note that the target file may not exist, i.e. the symlink may
+ LOAD PATH section below for more details. Note that the target file might not exist, i.e. the symlink may
be dangling.</para>
<para>Unit files may specify aliases through the <varname>Alias=</varname> directive in the [Install]
@@ -190,7 +198,7 @@
<filename>.wants/</filename> or <filename>.requires/</filename> must thus point to a valid unit file
location, i.e. the symlink target name must satisfy the described requirements, and the destination path
must be in one of the unit search paths, see UNIT FILE LOAD PATH section below for more details. Note
- that the target file may not exist, i.e. the symlink may be dangling.</para>
+ that the target file might not exist, i.e. the symlink may be dangling.</para>
<para>Along with a unit file <filename>foo.service</filename>, a "drop-in" directory
<filename>foo.service.d/</filename> may exist. All files with the suffix
@@ -345,7 +353,9 @@
<para>Unit files are loaded from a set of paths determined during
compilation, described in the two tables below. Unit files found
in directories listed earlier override files with the same name in
- directories lower in the list.</para>
+ directories lower in the list
+ <xi:include href="standard-conf.xml" xpointer="usr-local-footnote" />.
+ </para>
<para>When the variable <varname>$SYSTEMD_UNIT_PATH</varname> is set,
the contents of this variable overrides the unit load path. If
@@ -399,7 +409,7 @@
</row>
<row>
<entry><filename>/usr/local/lib/systemd/system</filename></entry>
- <entry>System units installed by the administrator </entry>
+ <entry>System units installed by the administrator</entry>
</row>
<row>
<entry><filename>/usr/lib/systemd/system</filename></entry>
@@ -920,6 +930,16 @@
</varlistentry>
<varlistentry>
+ <term><varname>WantsMountsFor=</varname></term>
+
+ <listitem><para>Same as <varname>RequiresMountsFor=</varname>,
+ but adds dependencies of type <varname>Wants=</varname> instead
+ of <varname>Requires=</varname>.</para>
+
+ <xi:include href="version-info.xml" xpointer="v256"/></listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><varname>OnSuccessJobMode=</varname></term>
<term><varname>OnFailureJobMode=</varname></term>
@@ -1067,9 +1087,8 @@
<option>exit-force</option>, <option>soft-reboot</option>, <option>soft-reboot-force</option>,
<option>kexec</option>, <option>kexec-force</option>, <option>halt</option>,
<option>halt-force</option> and <option>halt-immediate</option>. In system mode, all options are
- allowed. In user mode, only <option>none</option>, <option>exit</option>,
- <option>exit-force</option>, <option>soft-reboot</option> and <option>soft-reboot-force</option> are
- allowed. Both options default to <option>none</option>.</para>
+ allowed. In user mode, only <option>none</option>, <option>exit</option>, and
+ <option>exit-force</option> are allowed. Both options default to <option>none</option>.</para>
<para>If <option>none</option> is set, no action will be triggered. <option>reboot</option> causes a
reboot following the normal shutdown procedure (i.e. equivalent to <command>systemctl
@@ -1144,7 +1163,8 @@
<listitem><para><varname>JobTimeoutAction=</varname> optionally configures an additional action to
take when the timeout is hit, see description of <varname>JobTimeoutSec=</varname> and
<varname>JobRunningTimeoutSec=</varname> above. It takes the same values as
- <varname>StartLimitAction=</varname>. Defaults to <option>none</option>.</para>
+ <varname>FailureAction=</varname>/<varname>SuccessAction=</varname>. Defaults to
+ <option>none</option>.</para>
<para><varname>JobTimeoutRebootArgument=</varname> configures an optional reboot string to pass to
the <citerefentry><refentrytitle>reboot</refentrytitle><manvolnum>2</manvolnum></citerefentry> system
@@ -1311,6 +1331,10 @@
<literal>arc-be</literal>, or
<literal>native</literal>.</para>
+ <para>Use
+ <citerefentry><refentrytitle>systemd-analyze</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+ for the complete list of known architectures.</para>
+
<para>The architecture is determined from the information returned by
<citerefentry project='man-pages'><refentrytitle>uname</refentrytitle><manvolnum>2</manvolnum></citerefentry>
and is thus subject to
@@ -1604,7 +1628,7 @@
to make sure they run before the stamp file's modification time gets reset indicating a completed
update.</para>
- <para>If the <varname>systemd.condition-needs-update=</varname> option is specified on the kernel
+ <para>If the <varname>systemd.condition_needs_update=</varname> option is specified on the kernel
command line (taking a boolean), it will override the result of this condition check, taking
precedence over any file modification time checks. If the kernel command line option is used,
<filename>systemd-update-done.service</filename> will not have immediate effect on any following
@@ -1634,18 +1658,26 @@
whether the system is booting up for the first time. This roughly means that <filename>/etc/</filename>
was unpopulated when the system started booting (for details, see "First Boot Semantics" in
<citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry>).
- First boot is considered finished (this condition will evaluate as false) after the manager
+ First Boot is considered finished (this condition will evaluate as false) after the manager
has finished the startup phase.</para>
<para>This condition may be used to populate <filename>/etc/</filename> on the first boot after
factory reset, or when a new system instance boots up for the first time.</para>
+ <para>Note that the service manager itself will perform setup steps during First Boot: it will
+ initialize
+ <citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry> and
+ preset all units, enabling or disabling them according to the
+ <citerefentry><refentrytitle>systemd.preset</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+ settings. Additional setup may be performed via units with
+ <varname>ConditionFirstBoot=yes</varname>.</para>
+
<para>For robustness, units with <varname>ConditionFirstBoot=yes</varname> should order themselves
before <filename>first-boot-complete.target</filename> and pull in this passive target with
<varname>Wants=</varname>. This ensures that in a case of an aborted first boot, these units will
be re-run during the next system startup.</para>
- <para>If the <varname>systemd.condition-first-boot=</varname> option is specified on the kernel
+ <para>If the <varname>systemd.condition_first_boot=</varname> option is specified on the kernel
command line (taking a boolean), it will override the result of this condition check, taking
precedence over <filename>/etc/machine-id</filename> existence checks.</para>
@@ -2283,6 +2315,11 @@
<entry>This is the value of the <literal>$CREDENTIALS_DIRECTORY</literal> environment variable if available. See section "Credentials" in <citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry> for more information.</entry>
</row>
<row>
+ <entry><literal>%D</literal></entry>
+ <entry>Shared data directory</entry>
+ <entry>This is either <filename>/usr/share/</filename> (for the system manager) or the path <literal>$XDG_DATA_HOME</literal> resolves to (for user managers).</entry>
+ </row>
+ <row>
<entry><literal>%E</literal></entry>
<entry>Configuration directory root</entry>
<entry>This is either <filename>/etc/</filename> (for the system manager) or the path <literal>$XDG_CONFIG_HOME</literal> resolves to (for user managers).</entry>
@@ -2629,28 +2666,27 @@ OnFailure=failure-handler@%N.service
<refsect1>
<title>See Also</title>
- <para>
- <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd-system.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.special</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.device</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.mount</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.automount</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.swap</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.target</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.path</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.timer</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.scope</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.slice</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd-analyze</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
- <citerefentry project='man-pages'><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>systemd.directives</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
- <citerefentry project='man-pages'><refentrytitle>uname</refentrytitle><manvolnum>1</manvolnum></citerefentry>
- </para>
+ <para><simplelist type="inline">
+ <member><citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd-system.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.special</refentrytitle><manvolnum>7</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.device</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.mount</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.automount</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.swap</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.target</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.path</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.timer</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.scope</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.slice</refentrytitle><manvolnum>5</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>7</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd-analyze</refentrytitle><manvolnum>1</manvolnum></citerefentry></member>
+ <member><citerefentry project='man-pages'><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry></member>
+ <member><citerefentry><refentrytitle>systemd.directives</refentrytitle><manvolnum>7</manvolnum></citerefentry></member>
+ <member><citerefentry project='man-pages'><refentrytitle>uname</refentrytitle><manvolnum>1</manvolnum></citerefentry></member>
+ </simplelist></para>
</refsect1>
-
</refentry>