1 <?xml version='
1.0'
?> <!--*-nxml-*-->
2 <!DOCTYPE refentry PUBLIC
"-//OASIS//DTD DocBook XML V4.2//EN"
3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
6 SPDX-License-Identifier: LGPL-2.1+
9 <refentry id=
"shutdown"
10 xmlns:
xi=
"http://www.w3.org/2001/XInclude">
13 <title>shutdown
</title>
14 <productname>systemd
</productname>
18 <refentrytitle>shutdown
</refentrytitle>
19 <manvolnum>8</manvolnum>
23 <refname>shutdown
</refname>
24 <refpurpose>Halt, power-off or reboot the machine
</refpurpose>
29 <command>shutdown
</command>
30 <arg choice=
"opt" rep=
"repeat">OPTIONS
</arg>
31 <arg choice=
"opt">TIME
</arg>
32 <arg choice=
"opt" rep=
"repeat">WALL
</arg>
37 <title>Description
</title>
39 <para><command>shutdown
</command> may be used to halt, power-off
40 or reboot the machine.
</para>
42 <para>The first argument may be a time string (which is usually
43 <literal>now
</literal>). Optionally, this may be followed by a
44 wall message to be sent to all logged-in users before going
47 <para>The time string may either be in the format
48 <literal>hh:mm
</literal> for hour/minutes specifying the time to
49 execute the shutdown at, specified in
24h clock format.
50 Alternatively it may be in the syntax
<literal>+m
</literal>
51 referring to the specified number of minutes m from now.
52 <literal>now
</literal> is an alias for
<literal>+
0</literal>, i.e.
53 for triggering an immediate shutdown. If no time argument is
54 specified,
<literal>+
1</literal> is implied.
</para>
56 <para>Note that to specify a wall message you must specify a time
59 <para>If the time argument is used,
5 minutes before the system
60 goes down the
<filename>/run/nologin
</filename> file is created to
61 ensure that further logins shall not be allowed.
</para>
65 <title>Options
</title>
67 <para>The following options are understood:
</para>
71 <term><option>--help
</option></term>
73 <xi:include href=
"standard-options.xml" xpointer=
"help-text" />
77 <term><option>-H
</option></term>
78 <term><option>--halt
</option></term>
80 <listitem><para>Halt the machine.
</para></listitem>
84 <term><option>-P
</option></term>
85 <term><option>--poweroff
</option></term>
87 <listitem><para>Power-off the machine (the
88 default).
</para></listitem>
92 <term><option>-r
</option></term>
93 <term><option>--reboot
</option></term>
95 <listitem><para>Reboot the
96 machine.
</para></listitem>
100 <term><option>-h
</option></term>
102 <listitem><para>Equivalent to
<option>--poweroff
</option>,
103 unless
<option>--halt
</option> is specified.
</para></listitem>
107 <term><option>-k
</option></term>
109 <listitem><para>Do not halt, power-off, reboot, just write
110 wall message.
</para></listitem>
114 <term><option>--no-wall
</option></term>
116 <listitem><para>Do not send wall
118 halt, power-off, reboot.
</para></listitem>
122 <term><option>-c
</option></term>
124 <listitem><para>Cancel a pending shutdown. This may be used
125 cancel the effect of an invocation of
126 <command>shutdown
</command> with a time argument that is not
127 <literal>+
0</literal> or
128 <literal>now
</literal>.
</para></listitem>
135 <title>Exit status
</title>
137 <para>On success,
0 is returned, a non-zero failure code
142 <title>See Also
</title>
144 <citerefentry><refentrytitle>systemd
</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
145 <citerefentry><refentrytitle>systemctl
</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
146 <citerefentry><refentrytitle>halt
</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
147 <citerefentry project='man-pages'
><refentrytitle>wall
</refentrytitle><manvolnum>1</manvolnum></citerefentry>