[Next] [Previous] [Up] [Top] [Contents]

6.7.2 Shutdown programs

6.7.2.1 shutdown

This is an automated procedure to warn users and then brings the system down. When complete you can then power off the system or reboot. shutdown must be run as root. As an example, to shutdown the system in 10 minutes followed by a reboot, for SunOS 4.X, execute:

# shutdown -r +10 - reboot in 10 minutes.

SunOS 5.X, which uses a different shutdown program. This program is a shell script to take you to the desired run state and is located in /usr/sbin. You can specify a grace period (-g) in seconds, a run level (-i), and auto-confirmation of answers (-y). So to halt the system in 2 minutes while warning the users of the impending shutdown execute:

# shutdown -y -g120 -i0


Unix System Administration - 8 AUG 1996
[Next] [Previous] [Up] [Top] [Contents]