]>
Commit | Line | Data |
---|---|---|
160cd5c9 | 1 | <?xml version='1.0'?> <!--*-nxml-*--> |
3a54a157 | 2 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" |
12b42c76 | 3 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> |
db9ecf05 | 4 | <!-- SPDX-License-Identifier: LGPL-2.1-or-later --> |
160cd5c9 | 5 | |
269d17f9 | 6 | <refentry id="poweroff" |
798d3a52 ZJS |
7 | xmlns:xi="http://www.w3.org/2001/XInclude"> |
8 | ||
9 | <refentryinfo> | |
269d17f9 | 10 | <title>poweroff</title> |
798d3a52 | 11 | <productname>systemd</productname> |
798d3a52 ZJS |
12 | </refentryinfo> |
13 | ||
14 | <refmeta> | |
269d17f9 | 15 | <refentrytitle>poweroff</refentrytitle> |
798d3a52 ZJS |
16 | <manvolnum>8</manvolnum> |
17 | </refmeta> | |
18 | ||
19 | <refnamediv> | |
798d3a52 ZJS |
20 | <refname>poweroff</refname> |
21 | <refname>reboot</refname> | |
269d17f9 ZJS |
22 | <refname>halt</refname> |
23 | <refpurpose>Power off, reboot, or halt the machine</refpurpose> | |
798d3a52 ZJS |
24 | </refnamediv> |
25 | ||
26 | <refsynopsisdiv> | |
27 | <cmdsynopsis> | |
269d17f9 | 28 | <command>poweroff</command> |
798d3a52 ZJS |
29 | <arg choice="opt" rep="repeat">OPTIONS</arg> |
30 | </cmdsynopsis> | |
31 | <cmdsynopsis> | |
269d17f9 | 32 | <command>reboot</command> |
798d3a52 ZJS |
33 | <arg choice="opt" rep="repeat">OPTIONS</arg> |
34 | </cmdsynopsis> | |
35 | <cmdsynopsis> | |
269d17f9 | 36 | <command>halt</command> |
798d3a52 ZJS |
37 | <arg choice="opt" rep="repeat">OPTIONS</arg> |
38 | </cmdsynopsis> | |
39 | </refsynopsisdiv> | |
40 | ||
41 | <refsect1> | |
42 | <title>Description</title> | |
43 | ||
269d17f9 ZJS |
44 | <para><command>poweroff</command>, <command>reboot</command>, and <command>halt</command> may be used to |
45 | power off, reboot, or halt the machine. All three commands take the same options.</para> | |
798d3a52 ZJS |
46 | |
47 | </refsect1> | |
48 | ||
49 | <refsect1> | |
50 | <title>Options</title> | |
51 | ||
52 | <para>The following options are understood:</para> | |
53 | ||
54 | <variablelist> | |
55 | <varlistentry> | |
56 | <term><option>--help</option></term> | |
57 | ||
58 | <xi:include href="standard-options.xml" xpointer="help-text" /> | |
ec07c3c8 AK |
59 | |
60 | <xi:include href="version-info.xml" xpointer="v253"/> | |
798d3a52 ZJS |
61 | </varlistentry> |
62 | ||
63 | <varlistentry> | |
64 | <term><option>--halt</option></term> | |
65 | ||
66 | <listitem><para>Halt the machine, regardless of which one of | |
ec07c3c8 AK |
67 | the three commands is invoked.</para> |
68 | ||
69 | <xi:include href="version-info.xml" xpointer="v253"/></listitem> | |
798d3a52 ZJS |
70 | </varlistentry> |
71 | ||
72 | <varlistentry> | |
73 | <term><option>-p</option></term> | |
74 | <term><option>--poweroff</option></term> | |
75 | ||
269d17f9 | 76 | <listitem><para>Power off the machine, when either <command>halt</command> |
6dfaeac3 | 77 | or <command>poweroff</command> is invoked. This option is ignored when |
ec07c3c8 AK |
78 | <command>reboot</command> is invoked.</para> |
79 | ||
80 | <xi:include href="version-info.xml" xpointer="v253"/></listitem> | |
798d3a52 ZJS |
81 | </varlistentry> |
82 | ||
83 | <varlistentry> | |
84 | <term><option>--reboot</option></term> | |
85 | ||
86 | <listitem><para>Reboot the machine, regardless of which one of | |
ec07c3c8 AK |
87 | the three commands is invoked.</para> |
88 | ||
89 | <xi:include href="version-info.xml" xpointer="v253"/></listitem> | |
798d3a52 ZJS |
90 | </varlistentry> |
91 | ||
92 | <varlistentry> | |
93 | <term><option>-f</option></term> | |
94 | <term><option>--force</option></term> | |
95 | ||
cb195174 | 96 | <listitem> |
269d17f9 ZJS |
97 | <para>Force immediate power-off, halt, or reboot. If specified, the command does not contact the |
98 | init system. In most cases, filesystems are not properly unmounted before shutdown. For example, | |
99 | the command <command>reboot -f</command> is mostly equivalent to | |
100 | <command>systemctl reboot -ff</command>, instead of <command>systemctl reboot -f</command>. | |
101 | </para> | |
ec07c3c8 AK |
102 | |
103 | <xi:include href="version-info.xml" xpointer="v253"/> | |
cb195174 | 104 | </listitem> |
798d3a52 ZJS |
105 | </varlistentry> |
106 | ||
107 | <varlistentry> | |
108 | <term><option>-w</option></term> | |
109 | <term><option>--wtmp-only</option></term> | |
110 | ||
269d17f9 | 111 | <listitem><para>Only write wtmp shutdown entry, do not actually power off, reboot, or halt. |
ec07c3c8 AK |
112 | </para> |
113 | ||
114 | <xi:include href="version-info.xml" xpointer="v253"/></listitem> | |
798d3a52 ZJS |
115 | </varlistentry> |
116 | ||
117 | <varlistentry> | |
118 | <term><option>-d</option></term> | |
119 | <term><option>--no-wtmp</option></term> | |
120 | ||
ec07c3c8 AK |
121 | <listitem><para>Do not write wtmp shutdown entry.</para> |
122 | ||
123 | <xi:include href="version-info.xml" xpointer="v253"/></listitem> | |
798d3a52 | 124 | </varlistentry> |
f3f054f0 TB |
125 | |
126 | <varlistentry> | |
127 | <term><option>-n</option></term> | |
128 | <term><option>--no-sync</option></term> | |
129 | ||
269d17f9 | 130 | <listitem><para>Don't sync hard disks/storage media before power-off, reboot, or halt. |
ec07c3c8 AK |
131 | </para> |
132 | ||
133 | <xi:include href="version-info.xml" xpointer="v253"/></listitem> | |
f3f054f0 | 134 | </varlistentry> |
798d3a52 ZJS |
135 | |
136 | <varlistentry> | |
137 | <term><option>--no-wall</option></term> | |
138 | ||
ec07c3c8 AK |
139 | <listitem><para>Do not send wall message before power-off, reboot, or halt.</para> |
140 | ||
141 | <xi:include href="version-info.xml" xpointer="v253"/></listitem> | |
798d3a52 ZJS |
142 | </varlistentry> |
143 | </variablelist> | |
144 | </refsect1> | |
145 | ||
146 | <refsect1> | |
147 | <title>Exit status</title> | |
148 | ||
269d17f9 | 149 | <para>On success, 0 is returned, a non-zero failure code otherwise.</para> |
798d3a52 ZJS |
150 | </refsect1> |
151 | ||
152 | <refsect1> | |
153 | <title>Notes</title> | |
154 | ||
59d83463 | 155 | <para>These commands are implemented in a way that preserves basic compatibility with the original SysV |
269d17f9 ZJS |
156 | commands. <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry> |
157 | verbs <command>poweroff</command>, <command>reboot</command>, <command>halt</command> provide the same | |
59d83463 LP |
158 | functionality with some additional features.</para> |
159 | ||
160 | <para>Note that on many SysV systems <command>halt</command> used to be synonymous to | |
161 | <command>poweroff</command>, i.e. both commands would equally result in powering the machine off. systemd | |
162 | is more accurate here, and <command>halt</command> results in halting the machine only (leaving power | |
163 | on), and <command>poweroff</command> is required to actually power it off.</para> | |
798d3a52 ZJS |
164 | </refsect1> |
165 | ||
166 | <refsect1> | |
167 | <title>See Also</title> | |
168 | <para> | |
169 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
170 | <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
171 | <citerefentry><refentrytitle>shutdown</refentrytitle><manvolnum>8</manvolnum></citerefentry>, | |
172 | <citerefentry project='man-pages'><refentrytitle>wall</refentrytitle><manvolnum>1</manvolnum></citerefentry> | |
173 | </para> | |
174 | </refsect1> | |
160cd5c9 LP |
175 | |
176 | </refentry> |