1SYSTEMD-SUSPEND.SERVICE(8)  systemd-suspend.service SYSTEMD-SUSPEND.SERVICE(8)
2
3
4

NAME

6       systemd-suspend.service, systemd-hibernate.service, systemd-hybrid-
7       sleep.service, systemd-suspend-then-hibernate.service, systemd-sleep -
8       System sleep state logic
9

SYNOPSIS

11       systemd-suspend.service
12
13       systemd-hibernate.service
14
15       systemd-hybrid-sleep.service
16
17       systemd-suspend-then-hibernate.service
18
19       /usr/lib/systemd/system-sleep
20

DESCRIPTION

22       systemd-suspend.service is a system service that is pulled in by
23       suspend.target and is responsible for the actual system suspend.
24       Similarly, systemd-hibernate.service is pulled in by hibernate.target
25       to execute the actual hibernation. Finally,
26       systemd-hybrid-sleep.service is pulled in by hybrid-sleep.target to
27       execute hybrid hibernation with system suspend and pulled in by
28       suspend-then-hibernate.target to execute system suspend with a timeout
29       that will activate hibernate later.
30
31       Immediately before entering system suspend and/or hibernation
32       systemd-suspend.service (and the other mentioned units, respectively)
33       will run all executables in /usr/lib/systemd/system-sleep/ and pass two
34       arguments to them. The first argument will be "pre", the second either
35       "suspend", "hibernate", "hybrid-sleep", or "suspend-then-hibernate"
36       depending on the chosen action. Immediately after leaving system
37       suspend and/or hibernation the same executables are run, but the first
38       argument is now "post". All executables in this directory are executed
39       in parallel, and execution of the action is not continued until all
40       executables have finished.
41
42       Note that scripts or binaries dropped in /usr/lib/systemd/system-sleep/
43       are intended for local use only and should be considered hacks. If
44       applications want to react to system suspend/hibernation and resume,
45       they should rather use the Inhibitor interface[1].
46
47       Note that systemd-suspend.service, systemd-hibernate.service,
48       systemd-hybrid-sleep.service, and
49       systemd-suspend-then-hibernate.service should never be executed
50       directly. Instead, trigger system sleep with a command such as
51       systemctl suspend or systemctl hibernate.
52
53       Internally, this service will echo a string like "mem" into
54       /sys/power/state, to trigger the actual system suspend. What exactly is
55       written where can be configured in the [Sleep] section of
56       /etc/systemd/sleep.conf or a sleep.conf.d file. See systemd-
57       sleep.conf(5).
58

OPTIONS

60       systemd-sleep understands the following commands:
61
62       -h, --help
63           Print a short help text and exit.
64
65       --version
66           Print a short version string and exit.
67
68       suspend, hibernate, hybrid-sleep, suspend-then-hibernate
69           Suspend, hibernate, suspend then hibernate, or put the system to
70           hybrid sleep.
71

SEE ALSO

73       systemd-sleep.conf(5), systemd(1), systemctl(1), systemd.special(7),
74       systemd-halt.service(8)
75

NOTES

77        1. Inhibitor interface
78           https://www.freedesktop.org/wiki/Software/systemd/inhibit
79
80
81
82systemd 246                                         SYSTEMD-SUSPEND.SERVICE(8)
Impressum