1 .\" Copyright (c) 1988, 1991, 1993
2 .\" The Regents of the University of California. All rights reserved.
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
12 .\" 3. Neither the name of the University nor the names of its contributors
13 .\" may be used to endorse or promote products derived from this software
14 .\" without specific prior written permission.
16 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
17 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
20 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28 .\" @(#)shutdown.8 8.2 (Berkeley) 4/27/95
37 .Nd "close down the system at a given time"
50 .Op Ar warning-message ...
55 utility provides an automated shutdown procedure for super-users
56 to nicely notify users when the system is shutting down,
57 saving them from system administrators, hackers, and gurus, who
58 would otherwise not bother with such niceties.
60 The following options are available:
61 .Bl -tag -width indent
63 The system is power cycled (power turned off and then back on)
64 at the specified time.
65 If the hardware doesn't support power cycle, the system will be
67 At the present time, only systems with BMC supported by the
69 driver that implement this functionality support this flag.
70 The amount of time the system is off is dependent on the device
71 that implements this feature.
73 The system is halted at the specified
76 The system is halted and the power is turned off
77 (hardware support required, otherwise the system is halted)
81 The system is rebooted at the specified
88 does not actually halt the system, but leaves the
89 system multi-user with logins disabled (for all but super-user).
97 options are specified,
103 instead of sending a signal to
108 option is specified, prevent the file system cache from being flushed by passing
114 This option should probably not be used.
119 will bring the system down and
120 may be the case-insensitive word
122 (indicating an immediate shutdown) or
123 a future time in one of two formats:
127 where the year, month, and day may be defaulted
128 to the current system values.
129 The first form brings the system down in
131 minutes and the second at the absolute time specified.
133 may be specified in units other than minutes by appending the corresponding
142 If an absolute time is specified, but not a date,
143 and that time today has already passed,
145 will assume that the same time tomorrow was meant.
146 (If a complete date is specified which has already passed,
148 will print an error and exit without shutting the system down.)
149 .It Ar warning-message
150 Any other arguments comprise the warning message that is broadcast
151 to users currently logged into the system.
155 is supplied as an option, the warning message is read from the standard
159 At intervals, becoming more frequent as apocalypse approaches
160 and starting at ten hours before shutdown, warning messages are displayed
161 on the terminals of all users logged in.
163 shutdown, or immediately if shutdown is in less than 5 minutes,
164 logins are disabled by creating
167 warning message there.
168 If this file exists when a user attempts to
171 prints its contents and exits.
177 At shutdown time a message is written to the system log, containing the
178 time of shutdown, the person who initiated the shutdown and the reason.
179 The corresponding signal is then sent to
181 to respectively halt, reboot or bring the system down to single-user state
182 (depending on the above options).
183 The time of the shutdown and the warning message
186 and should be used to
187 inform the users about when the system will be back up
188 and why it is going down (or anything else).
190 A scheduled shutdown can be canceled by killing the
199 created will be removed automatically.
201 When run without options, the
203 utility will place the system into single user mode at the
209 is equivalent to running:
210 .Bd -literal -offset indent
214 .Bl -tag -width /var/run/nologin -compact
215 .It Pa /var/run/nologin
218 not to let anyone log in
221 Reboot the system in 30 minutes and display a warning message on the terminals
222 of all users currently logged in:
224 .Dl # shutdown -r +30 \&"System will reboot\&"
226 The hours and minutes in the second time format may be separated by
227 a colon (``:'') for backward compatibility.
239 command was originally written by Ian Johnstone for UNSW's modified
241 It was modified and then incorporated in