source: general/sysutils/pm-utils.xml

trunk
Last change on this file was 5d0e7b8, checked in by Douglas R. Reno <renodr@…>, 2 months ago

A bunch of tags

  • Property mode set to 100644
File size: 11.2 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY pm-utils-download-http "https://pm-utils.freedesktop.org/releases/pm-utils-&pm-utils-version;.tar.gz">
8 <!ENTITY pm-utils-download-ftp " ">
9 <!ENTITY pm-utils-md5sum "1742a556089c36c3a89eb1b957da5a60">
10 <!ENTITY pm-utils-size "204 KB">
11 <!ENTITY pm-utils-buildsize "1.6 MB">
12 <!ENTITY pm-utils-time "0.1 SBU">
13]>
14
15<sect1 id="pm-utils" xreflabel="pm-utils-&pm-utils-version;">
16 <?dbhtml filename="pm-utils.html"?>
17
18
19 <title>pm-utils-&pm-utils-version;</title>
20
21 <indexterm zone="pm-utils">
22 <primary sortas="a-pm-utils">pm-utils</primary>
23 </indexterm>
24
25 <sect2 role="package">
26 <title>Introduction to Power Management Utilities</title>
27
28 <para>
29 The <application>Power Management Utilities</application> provide
30 simple shell command line tools to suspend and hibernate the computer.
31 They can be used to run user supplied scripts on suspend and resume.
32 </para>
33
34 <note revision='systemd'>
35 <para>
36 On a system using <application>systemd</application> as the init
37 system, <application>systemd</application> already provides this
38 functionality. As a result, this package is probably not needed, and it
39 may conflict with <application>systemd</application>. Read the
40 documentation for <filename>suspend.target</filename> and
41 <filename>hibernate.target</filename> in the man page
42 <ulink role='man'
43 url='&man;systemd.special.7'>systemd.special(7)</ulink> for more
44 details.
45 </para>
46 </note>
47
48 &lfs121_checked;
49
50 <bridgehead renderas="sect3">Package Information</bridgehead>
51 <itemizedlist spacing="compact">
52 <listitem>
53 <para>
54 Download (HTTP): <ulink url="&pm-utils-download-http;"/>
55 </para>
56 </listitem>
57 <listitem>
58 <para>
59 Download (FTP): <ulink url="&pm-utils-download-ftp;"/>
60 </para>
61 </listitem>
62 <listitem>
63 <para>
64 Download MD5 sum: &pm-utils-md5sum;
65 </para>
66 </listitem>
67 <listitem>
68 <para>
69 Download size: &pm-utils-size;
70 </para>
71 </listitem>
72 <listitem>
73 <para>
74 Estimated disk space required: &pm-utils-buildsize;
75 </para>
76 </listitem>
77 <listitem>
78 <para>
79 Estimated build time: &pm-utils-time;
80 </para>
81 </listitem>
82 </itemizedlist>
83
84 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
85 <itemizedlist spacing="compact">
86 <listitem>
87 <para>
88 Required patch:
89 <ulink url="&patch-root;/pm-utils-&pm-utils-version;-bugfixes-1.patch"/>
90 </para>
91 </listitem>
92 </itemizedlist>
93
94 <bridgehead renderas="sect3">Power Management Utilities Dependencies</bridgehead>
95
96 <bridgehead renderas="sect4">Optional</bridgehead>
97 <para role="optional">
98 <xref linkend="xmlto"/> (to generate man pages)
99 </para>
100
101 <bridgehead renderas="sect4">Optional (runtime)</bridgehead>
102 <para role="optional">
103 <xref role="runtime" linkend="hdparm"/>,
104 <xref role="runtime" linkend="wireless_tools"/>,
105 <ulink role="runtime"
106 url="https://www.kernel.org/pub/software/network/ethtool/">
107 ethtool</ulink>, and
108 <ulink role="runtime"
109 url="https://ftp.debian.org/debian/pool/main/v/vbetool/">
110 vbetool</ulink>
111 </para>
112
113 </sect2>
114
115 <sect2 role="kernel" id="pm-utils-kernel">
116 <title>Kernel Configuration</title>
117
118 <para>
119 If needed, enable the following options in the kernel configuration and
120 recompile the kernel:
121 </para>
122
123 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
124 href="pm-utils-kernel.xml"/>
125
126 <para>
127 Suspend to RAM allows the system to enter sleep states in which main
128 memory is powered and thus its contents are preserved. The method cuts
129 power to most parts of the machine aside from the RAM. Because of the
130 large power savings, it is advisable for laptops to automatically enter
131 this mode when the computer is running on batteries and the lid is closed
132 (or the user is inactive for some time).
133 </para>
134
135 <para>
136 Suspend to disk (Hibernation) saves the machine's state into swap space
137 and completely powers off the machine. When the machine is powered on,
138 the state is restored. Until then, there is zero power consumption.
139 Suspend to RAM and hibernation are normally appropriate for portable
140 devices such as laptops, but can be used on workstations. The capability
141 is not really appropriate for servers.
142 </para>
143
144 <para>
145 To use hibernation, the kernel parameter
146 resume=/dev/&lt;swap_partition&gt; has to be used on the kernel command
147 line (in grub.cfg). The swap partition should be at least the size of
148 the physical RAM on the system.
149 </para>
150
151 <indexterm zone="pm-utils pm-utils-kernel">
152 <primary sortas="d-pm-utils">pm-utils</primary>
153 </indexterm>
154
155 </sect2>
156
157 <sect2 role="installation">
158 <title>Installation of Power Management Utilities</title>
159
160 <para>
161 First, fix several bugs and a couple of incompatibilities with newer
162 kernels:
163 </para>
164
165<screen><userinput remap="pre">patch -Np1 -i ../pm-utils-&pm-utils-version;-bugfixes-1.patch</userinput></screen>
166
167 <para>
168 Install <application>Power Management Utilities</application> by
169 running the following commands:
170 </para>
171
172<screen><userinput>./configure --prefix=/usr \
173 --sysconfdir=/etc \
174 --docdir=/usr/share/doc/pm-utils-&pm-utils-version; &amp;&amp;
175make</userinput></screen>
176
177 <para>
178 This package does not come with a test suite.
179 </para>
180
181 <para>
182 Now, as the <systemitem class="username">root</systemitem> user:
183 </para>
184
185<screen role="root"><userinput>make install</userinput></screen>
186
187 <para>
188 If you don't have <xref linkend="xmlto"/> installed, copy pregenerated
189 man pages, as the <systemitem class="username">root</systemitem> user:
190 </para>
191
192<screen role="root"><userinput>install -v -m644 man/*.1 /usr/share/man/man1 &amp;&amp;
193install -v -m644 man/*.8 /usr/share/man/man8 &amp;&amp;
194ln -sv pm-action.8 /usr/share/man/man8/pm-suspend.8 &amp;&amp;
195ln -sv pm-action.8 /usr/share/man/man8/pm-hibernate.8 &amp;&amp;
196ln -sv pm-action.8 /usr/share/man/man8/pm-suspend-hybrid.8</userinput></screen>
197
198 </sect2>
199
200 <sect2 role="configuration">
201 <title>Configuring Power Management Utilities</title>
202
203 <para>
204 Suspend or resume functionality can be easily modified by installing files
205 into the <filename class="directory">/etc/pm/sleep.d</filename> directory.
206 These files, known as hooks, are run when the system is put into a sleep
207 state or resumed. Default hooks are located in <filename
208 class="directory">/usr/lib/pm-utils/sleep.d</filename>, and user hooks
209 should be put in <filename class="directory">/etc/pm/sleep.d</filename>.
210 See the <ulink role='man' url='&man;pm-action.8'>pm-action(8)</ulink>
211 man page for more information.
212 </para>
213
214 <para>
215 In order to use hibernation with <application>GRUB</application> and a
216 swap partition, you need to add kernel parameter
217 <literal>resume=<replaceable>swap_partition</replaceable></literal> (e.g.
218 <literal>resume=/dev/sda1</literal>) to the kernel line in the
219 <filename>/boot/grub/grub.cfg</filename> configuration file.
220 </para>
221
222 </sect2>
223
224 <sect2 role="content">
225 <title>Contents</title>
226
227 <segmentedlist>
228 <segtitle>Installed Programs</segtitle>
229 <segtitle>Installed Libraries</segtitle>
230 <segtitle>Installed Directories</segtitle>
231
232 <seglistitem>
233 <seg>
234 on_ac_power, pm-hibernate, pm-is-supported, pm-powersave, pm-suspend
235 and pm-suspend-hybrid
236 </seg>
237 <seg>
238 None
239 </seg>
240 <seg>
241 /etc/pm, /usr/lib/pm-utils and
242 /usr/share/doc/pm-utils-&pm-utils-version;
243 </seg>
244 </seglistitem>
245 </segmentedlist>
246
247 <variablelist>
248 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
249 <?dbfo list-presentation="list"?>
250 <?dbhtml list-presentation="table"?>
251
252 <varlistentry id="on_ac_power">
253 <term><command>on_ac_power</command></term>
254 <listitem>
255 <para>
256 is a script that determines whether the system is running on AC
257 power (rather than a battery)
258 </para>
259 <indexterm zone="pm-utils on_ac_power">
260 <primary sortas="b-on_ac_power">on_ac_power</primary>
261 </indexterm>
262 </listitem>
263 </varlistentry>
264
265 <varlistentry id="pm-hibernate">
266 <term><command>pm-hibernate</command></term>
267 <listitem>
268 <para>
269 is a symlink to pm-action script that puts the computer into
270 hibernate mode (the system is fully powered off and system state is
271 saved to disk)
272 </para>
273 <indexterm zone="pm-utils pm-hibernate">
274 <primary sortas="b-pm-hibernate">pm-hibernate</primary>
275 </indexterm>
276 </listitem>
277 </varlistentry>
278
279 <varlistentry id="pm-is-supported">
280 <term><command>pm-is-supported</command></term>
281 <listitem>
282 <para>
283 is a script that checks whether power management features such as
284 suspend and hibernate are supported
285 </para>
286 <indexterm zone="pm-utils pm-is-supported">
287 <primary sortas="b-pm-is-supported">pm-is-supported</primary>
288 </indexterm>
289 </listitem>
290 </varlistentry>
291
292 <varlistentry id="pm-powersave">
293 <term><command>pm-powersave</command></term>
294 <listitem>
295 <para>
296 is a script that puts the computer into powersaving (low power)
297 mode
298 </para>
299 <indexterm zone="pm-utils pm-powersave">
300 <primary sortas="b-pm-powersave">pm-powersave</primary>
301 </indexterm>
302 </listitem>
303 </varlistentry>
304
305 <varlistentry id="pm-suspend">
306 <term><command>pm-suspend</command></term>
307 <listitem>
308 <para>
309 is a symlink to pm-action script that puts the computer into suspend
310 mode (most devices are shut down and system state is saved in RAM)
311 </para>
312 <indexterm zone="pm-utils pm-suspend">
313 <primary sortas="b-pm-suspend">pm-suspend</primary>
314 </indexterm>
315 </listitem>
316 </varlistentry>
317
318 <varlistentry id="pm-suspend-hybrid">
319 <term><command>pm-suspend-hybrid</command></term>
320 <listitem>
321 <para>
322 is a symlink to pm-action script that puts the computer into
323 hybrid-suspend mode (the system does everything it needs to
324 hibernate, but suspends instead of shutting down)
325 </para>
326 <indexterm zone="pm-utils pm-suspend-hybrid">
327 <primary sortas="b-pm-suspend-hybrid">pm-suspend-hybrid</primary>
328 </indexterm>
329 </listitem>
330 </varlistentry>
331
332 </variablelist>
333
334 </sect2>
335
336</sect1>
Note: See TracBrowser for help on using the repository browser.