1SYSTEMD.KILL(5)                  systemd.kill                  SYSTEMD.KILL(5)
2
3
4

NAME

6       systemd.kill - Process killing procedure configuration
7

SYNOPSIS

9       service.service, socket.socket, mount.mount, swap.swap, scope.scope
10

DESCRIPTION

12       Unit configuration files for services, sockets, mount points, swap
13       devices and scopes share a subset of configuration options which define
14       the killing procedure of processes belonging to the unit.
15
16       This man page lists the configuration options shared by these five unit
17       types. See systemd.unit(5) for the common options shared by all unit
18       configuration files, and systemd.service(5), systemd.socket(5),
19       systemd.swap(5), systemd.mount(5) and systemd.scope(5) for more
20       information on the configuration file options specific to each unit
21       type.
22
23       The kill procedure configuration options are configured in the
24       [Service], [Socket], [Mount] or [Swap] section, depending on the unit
25       type.
26

OPTIONS

28       KillMode=
29           Specifies how processes of this unit shall be killed. One of
30           control-group, process, mixed, none.
31
32           If set to control-group, all remaining processes in the control
33           group of this unit will be killed on unit stop (for services: after
34           the stop command is executed, as configured with ExecStop=). If set
35           to process, only the main process itself is killed. If set to
36           mixed, the SIGTERM signal (see below) is sent to the main process
37           while the subsequent SIGKILL signal (see below) is sent to all
38           remaining processes of the unit's control group. If set to none, no
39           process is killed. In this case, only the stop command will be
40           executed on unit stop, but no process be killed otherwise.
41           Processes remaining alive after stop are left in their control
42           group and the control group continues to exist after stop unless it
43           is empty.
44
45           Processes will first be terminated via SIGTERM (unless the signal
46           to send is changed via KillSignal=). Optionally, this is
47           immediately followed by a SIGHUP (if enabled with SendSIGHUP=). If
48           processes still remain after the main process of a unit has exited
49           or the delay configured via the TimeoutStopSec= has passed, the
50           termination request is repeated with the SIGKILL signal or the
51           signal specified via FinalKillSignal= (unless this is disabled via
52           the SendSIGKILL= option). See kill(2) for more information.
53
54           Defaults to control-group.
55
56       KillSignal=
57           Specifies which signal to use when killing a service. This controls
58           the signal that is sent as first step of shutting down a unit (see
59           above), and is usually followed by SIGKILL (see above and below).
60           For a list of valid signals, see signal(7). Defaults to SIGTERM.
61
62           Note that, right after sending the signal specified in this
63           setting, systemd will always send SIGCONT, to ensure that even
64           suspended tasks can be terminated cleanly.
65
66       SendSIGHUP=
67           Specifies whether to send SIGHUP to remaining processes immediately
68           after sending the signal configured with KillSignal=. This is
69           useful to indicate to shells and shell-like programs that their
70           connection has been severed. Takes a boolean value. Defaults to
71           "no".
72
73       SendSIGKILL=
74           Specifies whether to send SIGKILL (or the signal specified by
75           FinalKillSignal=) to remaining processes after a timeout, if the
76           normal shutdown procedure left processes of the service around.
77           Takes a boolean value. Defaults to "yes".
78
79       FinalKillSignal=
80           Specifies which signal to send to remaining processes after a
81           timeout if SendSIGKILL= is enabled. The signal configured here
82           should be one that is not typically caught and processed by
83           services (SIGTERM is not suitable). Developers can find it useful
84           to use this to generate a coredump to troubleshoot why a service
85           did not terminate upon receiving the initial SIGTERM signal. This
86           can be achieved by configuring LimitCORE= and setting
87           FinalKillSignal= to either SIGQUIT or SIGABRT Defaults to SIGKILL.
88
89       WatchdogSignal=
90           Specifies which signal to use to terminate the service when the
91           watchdog timeout expires (enabled through WatchdogSec=). Defaults
92           to SIGABRT.
93

SEE ALSO

95       systemd(1), systemctl(1), journalctl(1), systemd.unit(5),
96       systemd.service(5), systemd.socket(5), systemd.swap(5),
97       systemd.mount(5), systemd.exec(5), systemd.directives(7), kill(2),
98       signal(7)
99
100
101
102systemd 241                                                    SYSTEMD.KILL(5)
Impressum