This chapter describes the basic system operating modes, the process of starting and shutting down the system, and so on.
Shut down the system in several cases, the system can be completely shut down or transferred to a medium level to complete maintenance work such as backup.
(i) System boot
Startup and shutdown systems are an important part of system management.
A boot (or boot) system is a part of the operating system that is loaded into memory and begins to initialize itself. Because the system has to "lift itself from its own self", it is called a boot or bootstrap.
When the system boots, the available memory and hard disk devices are identified. system hook/(root) file system and start important system processing (such as init,pscked,sendmail, etc.). Then make the user available for registration.
The/sbin/init process launches a series of shell scripts to complete the following tasks:
Sets the host name of the system.
Perform the File System Checker (FSCK).
Start daemons and network services.
Once the script has finished executing, the system is in Level 3.
Sometimes the system administrator must modify the launch shell script to start a new service.
(ii) System operating level
1. Operation Level Description
There are 8 system run levels in the Solaris 2.x environment, involving 4 levels:
(1) Operation Level 3
Run Level 3 is full multiuser mode. This is the default run level for the system and is also the default state of the system all system processing is performed, file resources are available to hook up and users can register.
(2) Operation level S,s
Run level S is Single-user mode and is a special run level. The operating system is executing, but all users are logged off, most of which are processed such as printing, Mail, etc., is not executed. Only one user, the Superuser, registers with the system. Run level S is convenient for performing backups because there is no user registration, so all data is stable. The system is brought into the run level s,s by the shutdown command.
(3) Operation level 0
This level closes the (shutdown) system to the prom level, so this level is safe for power off.
(4) Operation Level 5
This level shuts down (shutdown) the system to the power state.
(4) Operation Level 6
Run Level 6 is used to shut down (halt) system to level 0 and reboot to Level 3.
2. Show Run Level
Call the Who-r command to display the system's run level.
$ who-r
Run-level 3 Feb 6 15:46 3 2 S
In this case, the system is in the default Level 3. Other domains represent:
Feb 6 15:46
Date and time when the last run level changed.
3
Current run level.
2
The number of times this level has been run since the last reboot.
S
Previous run level.
3. Reasons for shutting down the system
(1) The SUNTM workstation is designed to work most of the time. But there are times when you have to shut down the system,
Run level S is used for system maintenance, such as complete backup. This system level change is still considered to be closed.
(2) Change the configuration of a system, such as adding or removing a tape drive or CD-ROM machine.
(3) Change the system hardware configuration, such as adding or removing a CPU board.
(4) from the extreme situation of recovery, if a hung workstation does not respond to all recovery work, may
You must turn off the power and start again.
4. Shutdown system (shutting down)
The way you shut down the system differs depending on the reason for the shutdown. The shutdown is done in order to go to execution level s, some to stop the operating system and power off the device.
Halt
Init 0
(3) Emergency shutdown
. In case of emergency, press STOP_A, if the stop_a does not work, power off the device and turn it on. It was a last resort.
Extreme situation. These two methods are not cleanly closed, are suddenly closed, only in emergency use.