TWiki
>
CF Web
>
Linux
>
LinuxAutomatedShutdownProcedure
(2006-02-08,
IsaacMorland
)
(raw view)
E
dit
A
ttach
---+ Automated Shutdown Procedure for Linux * These are for notes on automating a shutdown in preparation for a power outage or other outages. * The general procedure goes like this: 1 update motd a day or so before with the timing of the intended shutdown 1 update cron with the shutdown command a day or so before 1 if possible/necessary, send email to key users to let them know of the automated shutdown * For Solaris/Irix, see SolarisAutomatedShutdownProcedure ---++ Debian 1 ssh as root into the system to be shutdown, or login normally and sudo a new shell 1 update the motd <verbatim> # cd /etc # co -l motd (this may not work, in which case you can ignore it) # vi motd - add something like: March 22, 2005 ai0 will be shutdown at 4:30am Wednesday, March 23rd, for a planned power outage in DC. # ci -u motd (then this won't work either) </verbatim> 1 add the crontab entry: * if necessary, set the VISUAL variable for your shell. Most Debian systems will use vi by default. * In bash/sh, it can be done like this: <verbatim> # bash # VISUAL=vi # export VISUAL </verbatim> * In tcsh, it can be done like this: <verbatim> # tcsh # setenv VISUAL 'vi' </verbatim> 1 Then <verbatim> # crontab -e </verbatim> * and add lines to the end like: <verbatim> ### Temporary additon to handle scheduled power outage (trg 2005-3-20) 30 4 23 3 * /sbin/shutdown -h +5 "System shutdown in 5 min (power outage)" </verbatim> * Note in the above: "0 3 23 3 *" = 0 minutes, 3 hours (ie: 3am), 22nd day of any month, 3 - March, * any day of the week 1 (save and exit - this automatically updates the crontab) -- Main.TrevorGrove - 23 Mar 2005, based on equivalent Solaris procedures in SolarisAutomatedShutdownProcedure
E
dit
|
A
ttach
|
Watch
|
P
rint version
|
H
istory
: r3
<
r2
<
r1
|
B
acklinks
|
V
iew topic
|
WYSIWYG
|
M
ore topic actions
Topic revision: r3 - 2006-02-08
-
IsaacMorland
CF
Information in this area is meant for use by CSCF staff and is not official documentation, but anybody who is interested is welcome to use it if they find it useful.
CF Web
CF Web Home
Changes
Index
Search
Administration
Communication
Email
Hardware
HelpDeskGuide
Infrastructure
InternalProjects
Linux
MachineNotes
Macintosh
Management
Networking
Printing
Research
Security
Software
Solaris
StaffStuff
TaskGroups
TermGoals
Teaching
UserSupport
Vendors
Windows
XHier
Other Webs
CSEveryBody
Main
Sandbox
TWiki
UW
My links
People
CERAS
WatForm
Tetherless lab
Ubuntu Main.HowTo
eDocs
RGG NE notes
RGG
CS infrastructure
Grad images
Edit
Copyright © 2008-2025 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki?
Send feedback