歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Unix知識 >> 關於Unix >> Solaris如何改變系統運行級別 init

Solaris如何改變系統運行級別 init

日期:2017/2/28 11:20:23   编辑:關於Unix


系統運行級別有8種,分別為:
運行級別 意義
0 進入PROM狀態(OK狀態)
1 管理狀態(所有文件系統都掛上的單用戶模式,禁止其他用戶登錄)
2 多用戶模式(沒有網絡文件共享服務)
3 多用戶模式(有網絡文件共享服務)
4 未使用
5 退出操作系統並關機
6 重新啟動機器
S,s 單用戶模式
init
init命令用於改變操作系統的運行級別。
命令格式:
init [ 0123456Ss ]
# init 0
INIT: New run level: 0
The system is coming down. Please wait.
System services are now being stopped.
Print services stopped.
Stopping the syslog service.
syslogd: going down on signal 15
Aug 14 14:54:30 snmpdx: received signal 15
The system is down.
syncing file systems... done
Program terminated
Type help for more information
ok
shutdown
用於改變操作系統運行級別。
命令格式:
shutdown [ -y ] [ -g seconds ] [ -i init-state ] [message]
選項:
y 系統提示時默認回答為YES
g 過多長時間改變
i 想要的運行級別
message 給所有登錄用戶的信息
# shutdown -y -g 0 -i 0
Shutdown started. Mon Dec 15 15:13:57 PST 1997
Broadcast Message from root (console) on mcmurdo Mon Dec
15 15:13:57...
THE SYSTEM IS BEING SHUT DOWN NOW ! ! !
Log off now or risk your files being damaged
Changing to init state 0 - please wait
ok
halt
進入0運行級別
poweroff
關閉系統並切斷電源
reboot
重新啟動系統
Copyright © Linux教程網 All Rights Reserved