Sun Microsystems, Inc.
spacerspacer
spacer www.sun.com docs.sun.com |
spacer
black dot
 
 
12.  Shutting Down a System (Tasks) Shutting Down the System How to Shut Down a Server  Previous   Contents   Next 
   
 

SPARC: Example--Bringing a Server to Run Level S

In the following example, the shutdown is used to bring a SPARC based system to run level S (single-user level) in 3 minutes.

# who
root       console      Dec 13 14:30
# shutdown -g180 -y

Shutdown started.    Thu Dec 13 14:30:32 MST 2001

Broadcast Message from root (console) on earth Thu Dec 13 14:30:33...
The system earth will be shut down in 3 minutes 
.
.
.
Broadcast Message from root (console) on earth Thu Dec 13 14:30:33...
The system earth will be shut down in 30 seconds
.
.
.
INIT: New run level: S
The system is coming down for administration.  Please wait.
Unmounting remote filesystems: /vol nfs done.
Shutting down Solaris Management Console server on port 898.
Print services stopped.
Dec 13 14:34:00 earth syslogd: going down on signal 15
Killing user processes: done.

INIT: SINGLE USER MODE

Type control-d to proceed with normal startup,
(or give root password for system maintenance): xxx
Entering System Maintenance Mode ...
# 

SPARC: Example--Bringing a Server to Run Level 0

In the following example, the shutdown command is used to bring a SPARC based system to run level 0 in 5 minutes without requiring additional confirmation.

# who
root       console      Dec 12 08:08
rimmer     pts/0        Dec 11 14:48    (starbug)
pmorph     pts/1        Dec 13 12:31    (bluemidget)
# shutdown -i0 -g300 -y
Shutdown started.    Thu Dec 13 14:51:39 MST 2001

Broadcast Message from root (console) on earth Thu Dec 13 14:51:39...
The system earth will be shut down in 5 minutes 
.
.
.
Changing to init state 0 - please wait
# 
INIT: New run level: 0
The system is coming down.  Please wait.
System services are now being stopped.
.
.
.
The system is down.
syncing file systems... done
Program terminated
Type  help  for more information
ok 

If you are bringing the system to run level 0 to turn off power to all devices, see "How to Turn Off Power to All Devices".

SPARC: Example--Rebooting a Server to Run Level 3

In the following example, the shutdown command is used to reboot a SPARC based system to run level 3 in two minutes without requiring additional confirmation.

# who
root       console      Dec 12 08:08
rimmer     pts/0        Dec 11 14:48    (starbug)
pmorph     pts/1        Dec 13 12:31    (bluemidget)
# shutdown -i6 -g120 -y
Shutdown started.    Thu Dec 13 15:56:30

Broadcast Message from root (console) on earth Thu Dec 13 15:56:30...
The system earth will be shut down in 2 minutes 
.
.
.
Changing to init state 6 - please wait
# 
INIT: New run level: 6
The system is coming down.  Please wait.
.
.
.
The system is down.
syncing file systems... done
rebooting...
.
.
.
earth console login:

Where to Go From Here

Regardless of why you shut down a system, you'll probably want to return to run level 3 where all file resources are available and users can log in. For instructions on bringing a system back to a multiuser level, see Chapter 13, SPARC: Booting a System (Tasks) or Chapter 14, IA: Booting a System (Tasks).

How to Shut Down a Standalone System

Use this procedure when you need to shut down a standalone system.

  1. Become superuser.

  2. Shut down the system.

    # init run-level

    run-level identifies the new run level.

    For more information, see init(1M).

  3. Use the following table to verify that the system is at the run level that you specified in the init command.

    Specified Run Level

    SPARC System Prompt

    IA System Prompt

    S (single-user level)

    ##

    2 (multiuser level)

    ##

    0 (power-down level)

    ok or >type any key to continue

    3 (multiuser level with NFS resources shared)

    hostname console login:

    hostname console login:

 
 
 
  Previous   Contents   Next