pavement

Shutdown

From FreeBSDwiki
(Difference between revisions)
Jump to: navigation, search
m (Tell who can use this command)
(Common Flags and arguments)
Line 8: Line 8:
 
   
 
   
 
  '''now''' is a valid keyword for the "time" argument.
 
  '''now''' is a valid keyword for the "time" argument.
 +
 +
'''shutdown now''' prevent further logins, notify users of the impending (immediate) stop, halt most daemons, drop to [[single-user mode]].
  
 
'''shutdown -h now''' will halt the machine immediately - all users will be logged out forcefully, all pending writes will be performed, all disks sync'd, and the system will halt and wait for reboot.
 
'''shutdown -h now''' will halt the machine immediately - all users will be logged out forcefully, all pending writes will be performed, all disks sync'd, and the system will halt and wait for reboot.

Revision as of 16:10, 10 May 2006

Used to shutdown a machine. shutdown requires two arguments: a command and a time. By default, this command is only available to root and to the members of the operator group.

Common Flags and arguments

-h will halt the machine
-r will reboot the machine
-p will turn the power off after shutdown (only works on some BIOSes)
-k will send out a message that the machine will reboot, but not actually do it

now is a valid keyword for the "time" argument.

shutdown now prevent further logins, notify users of the impending (immediate) stop, halt most daemons, drop to single-user mode.

shutdown -h now will halt the machine immediately - all users will be logged out forcefully, all pending writes will be performed, all disks sync'd, and the system will halt and wait for reboot.

shutdown -h +5 will broadcast a console message to all currently logged in users warning them that the system will shutdown in 5 minutes, at which time it will forcefully log them out and do so.

shutdown -r 0412310000 will broadcast a console message warning users of a shutdown at midnight on New Year's Eve of 2004 (remember - that means 24 hours before 2005 arrives, not the minute the ball drops!), and at that time will forcefully log them out, halt the system, and automatically reboot.

Compare to init.

Personal tools