]> git.proxmox.com Git - systemd.git/blame - man/systemd-sleep.conf.5
Imported Upstream version 219
[systemd.git] / man / systemd-sleep.conf.5
CommitLineData
14228c0d 1'\" t
e735f4d4 2.TH "SYSTEMD\-SLEEP\&.CONF" "5" "" "systemd 219" "systemd-sleep.conf"
14228c0d
MB
3.\" -----------------------------------------------------------------
4.\" * Define some portability stuff
5.\" -----------------------------------------------------------------
6.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
7.\" http://bugs.debian.org/507673
8.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
9.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
10.ie \n(.g .ds Aq \(aq
11.el .ds Aq '
12.\" -----------------------------------------------------------------
13.\" * set default formatting
14.\" -----------------------------------------------------------------
15.\" disable hyphenation
16.nh
17.\" disable justification (adjust text to left margin only)
18.ad l
19.\" -----------------------------------------------------------------
20.\" * MAIN CONTENT STARTS HERE *
21.\" -----------------------------------------------------------------
22.SH "NAME"
f47781d8 23systemd-sleep.conf, sleep.conf.d \- Suspend and hibernation configuration file
14228c0d
MB
24.SH "SYNOPSIS"
25.PP
26/etc/systemd/sleep\&.conf
f47781d8
MP
27.PP
28/etc/systemd/sleep\&.conf\&.d/*\&.conf
29.PP
30/run/systemd/sleep\&.conf\&.d/*\&.conf
31.PP
32/usr/lib/systemd/sleep\&.conf\&.d/*\&.conf
14228c0d
MB
33.SH "DESCRIPTION"
34.PP
35\fBsystemd\fR
36supports three general power\-saving modes:
37.PP
38suspend
39.RS 4
40a low\-power state where execution of the OS is paused, and complete power loss might result in lost data, and which is fast to enter and exit\&. This corresponds to suspend, standby, or freeze states as understood by the kernel\&.
41.RE
42.PP
43hibernate
44.RS 4
45a low\-power state where execution of the OS is paused, and complete power loss does not result in lost data, and which might be slow to enter and exit\&. This corresponds to the hibernation as understood by the kernel\&.
46.RE
47.PP
48hybrid\-sleep
49.RS 4
50a low\-power state where execution of the OS is paused, which might be slow to enter, and on complete power loss does not result in lost data but might be slower to exit in that case\&. This mode is called suspend\-to\-both by the kernel\&.
51.RE
52.PP
f47781d8 53Settings in these files determine what strings will be written to
14228c0d
MB
54/sys/power/disk
55and
56/sys/power/state
57by
58\fBsystemd-sleep\fR(8)
59when
60\fBsystemd\fR(1)
61attempts to suspend or hibernate the machine\&.
f47781d8
MP
62.SH "CONFIGURATION DIRECTORIES AND PRECEDENCE"
63.PP
64Configuration files are read from directories in
65/etc/,
66/run/, and
67/usr/lib/, in order of precedence\&. Each configuration file in these configuration directories shall be named in the style of
68\fIfilename\fR\&.conf\&. Files in
69/etc/
70override files with the same name in
71/run/
72and
73/usr/lib/\&. Files in
74/run/
75override files with the same name in
76/usr/lib/\&.
77.PP
78Packages should install their configuration files in
79/usr/lib/\&. Files in
80/etc/
81are reserved for the local administrator, who may use this logic to override the configuration files installed by vendor packages\&. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in\&. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence\&. It is recommended to prefix all filenames with a two\-digit number and a dash, to simplify the ordering of the files\&.
82.PP
83If the administrator wants to disable a configuration file supplied by the vendor, the recommended way is to place a symlink to
84/dev/null
85in the configuration directory in
86/etc/, with the same filename as the vendor configuration file\&.
87.SH "CONFIGURATION FILE"
88.PP
89Configuration is also read from a single configuration file in
90/etc/\&. This file is read before any of the configuration directories, and has the lowest precedence; entries in a file in any configuration directory override entries in the single configuration file\&.
14228c0d
MB
91.SH "OPTIONS"
92.PP
93The following options can be configured in the
94"[Sleep]"
95section of
f47781d8
MP
96/etc/systemd/sleep\&.conf
97or a
98sleep\&.conf\&.d
99file:
14228c0d
MB
100.PP
101\fISuspendMode=\fR, \fIHibernateMode=\fR, \fIHybridSleepMode=\fR
102.RS 4
103The string to be written to
104/sys/power/disk
105by, respectively,
106\fBsystemd-suspend.service\fR(8),
107\fBsystemd-hibernate.service\fR(8), or
60f067b4 108\fBsystemd-hybrid-sleep.service\fR(8)\&. More than one value can be specified by separating multiple values with whitespace\&. They will be tried in turn, until one is written without error\&. If neither succeeds, the operation will be aborted\&.
14228c0d
MB
109.RE
110.PP
111\fISuspendState=\fR, \fIHibernateState=\fR, \fIHybridSleepState=\fR
112.RS 4
113The string to be written to
114/sys/power/state
115by, respectively,
116\fBsystemd-suspend.service\fR(8),
117\fBsystemd-hibernate.service\fR(8), or
60f067b4 118\fBsystemd-hybrid-sleep.service\fR(8)\&. More than one value can be specified by separating multiple values with whitespace\&. They will be tried in turn, until one is written without error\&. If neither succeeds, the operation will be aborted\&.
14228c0d
MB
119.RE
120.SH "EXAMPLE: FREEZE"
121.PP
122Example: to exploit the
123\(lqfreeze\(rq
124mode added in Linux 3\&.9, one can use
125\fBsystemctl suspend\fR
126with
127.sp
128.if n \{\
129.RS 4
130.\}
131.nf
132[Sleep]
133SuspendState=freeze
14228c0d
MB
134.fi
135.if n \{\
136.RE
137.\}
138.SH "SEE ALSO"
139.PP
140\fBsystemd-sleep\fR(8),
141\fBsystemd-suspend.service\fR(8),
142\fBsystemd-hibernate.service\fR(8),
143\fBsystemd-hybrid-sleep.service\fR(8),
144\fBsystemd\fR(1),
145\fBsystemd.directives\fR(7)