diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 03:50:42 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 03:50:42 +0000 |
commit | 78e9bb837c258ac0ec7712b3d612cc2f407e731e (patch) | |
tree | f515d16b6efd858a9aeb5b0ef5d6f90bf288283d /man/systemd.service.xml | |
parent | Adding debian version 255.5-1. (diff) | |
download | systemd-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.service.xml')
-rw-r--r-- | man/systemd.service.xml | 66 |
1 files changed, 38 insertions, 28 deletions
diff --git a/man/systemd.service.xml b/man/systemd.service.xml index 86d7108..58439df 100644 --- a/man/systemd.service.xml +++ b/man/systemd.service.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"> <!-- SPDX-License-Identifier: LGPL-2.1-or-later --> <refentry id="systemd.service" xmlns:xi="http://www.w3.org/2001/XInclude"> @@ -992,16 +992,22 @@ <listitem><para>Takes a list of exit status definitions that, when returned by the main service process, will prevent automatic service restarts, regardless of the restart setting configured with - <varname>Restart=</varname>. Exit status definitions can either be numeric exit codes or termination - signal names, and are separated by spaces. Defaults to the empty list, so that, by default, no exit - status is excluded from the configured restart logic. For example: + <varname>Restart=</varname>. Exit status definitions can be numeric termination statuses, termination + status names, or termination signal names, separated by spaces. Defaults to the empty list, so that, + by default, no exit status is excluded from the configured restart logic. - <programlisting>RestartPreventExitStatus=1 6 SIGABRT</programlisting> + <example> + <title>A service with the <varname>RestartPreventExitStatus=</varname> setting</title> + + <programlisting>RestartPreventExitStatus=TEMPFAIL 250 SIGKILL</programlisting> + + <para>Exit status 75 (<constant>TEMPFAIL</constant>), 250, and the termination signal + <constant>SIGKILL</constant> will not result in automatic service restarting.</para> + </example> - ensures that exit codes 1 and 6 and the termination signal <constant>SIGABRT</constant> will not - result in automatic service restarting. This option may appear more than once, in which case the list - of restart-preventing statuses is merged. If the empty string is assigned to this option, the list is - reset and all prior assignments of this option will have no effect.</para> + This option may appear more than once, in which case the list of restart-preventing statuses is merged. + If the empty string is assigned to this option, the list is reset and all prior assignments of this + option will have no effect.</para> <para>Note that this setting has no effect on processes configured via <varname>ExecStartPre=</varname>, <varname>ExecStartPost=</varname>, <varname>ExecStop=</varname>, @@ -1015,12 +1021,15 @@ <varlistentry> <term><varname>RestartForceExitStatus=</varname></term> - <listitem><para>Takes a list of exit status definitions that, - when returned by the main service process, will force automatic - service restarts, regardless of the restart setting configured - with <varname>Restart=</varname>. The argument format is - similar to - <varname>RestartPreventExitStatus=</varname>.</para> + + <listitem><para>Takes a list of exit status definitions that, when returned by the main service + process, will force automatic service restarts, regardless of the restart setting configured with + <varname>Restart=</varname>. The argument format is similar to <varname>RestartPreventExitStatus=</varname>. + </para> + + <para>Note that for <varname>Type=oneshot</varname> services, a success exit status will prevent + them from auto-restarting, no matter whether the corresponding exit statuses are listed in this + option or not.</para> <xi:include href="version-info.xml" xpointer="v215"/></listitem> </varlistentry> @@ -1313,8 +1322,9 @@ <varname>ExecStartPre=</varname>, <varname>ExecStartPost=</varname>, <varname>ExecReload=</varname>, - <varname>ExecStop=</varname>, and - <varname>ExecStopPost=</varname> options.</para> + <varname>ExecStop=</varname>, + <varname>ExecStopPost=</varname>, and + <varname>ExecCondition=</varname> options.</para> <para>Multiple command lines may be concatenated in a single directive by separating them with semicolons (these semicolons must be passed as separate words). Lone semicolons may be escaped as @@ -1752,17 +1762,17 @@ WantedBy=multi-user.target</programlisting> <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.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>, - <citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry>, - <citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry>, - <citerefentry><refentrytitle>systemd.kill</refentrytitle><manvolnum>5</manvolnum></citerefentry>, - <citerefentry><refentrytitle>systemd.directives</refentrytitle><manvolnum>7</manvolnum></citerefentry>, - <citerefentry><refentrytitle>systemd-run</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.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry></member> + <member><citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry></member> + <member><citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry></member> + <member><citerefentry><refentrytitle>systemd.kill</refentrytitle><manvolnum>5</manvolnum></citerefentry></member> + <member><citerefentry><refentrytitle>systemd.directives</refentrytitle><manvolnum>7</manvolnum></citerefentry></member> + <member><citerefentry><refentrytitle>systemd-run</refentrytitle><manvolnum>1</manvolnum></citerefentry></member> + </simplelist></para> </refsect1> </refentry> |