詳解 Linux中的關(guān)機(jī)和重啟命令
一 shutdown命令
shutdown [選項(xiàng)] 時(shí)間
選項(xiàng):
-c:取消前一次關(guān)機(jī)命令-h:關(guān)機(jī)-r:重啟
二 shutdown實(shí)戰(zhàn)
[root@localhost tmp]# dateSat Jul 15 09:28:35 CST 2017[root@localhost tmp]# shutdown -r 05:30Shutdown scheduled for Sun 2017-07-16 05:30:00 CST, use 'shutdown -c' to cancel.[root@localhost tmp]# shutdown -r 05:30 &[1] 4936[root@localhost tmp]# Shutdown scheduled for Sun 2017-07-16 05:30:00 CST, use 'shutdown -c' to cancel. Broadcast message from [email protected] (Sat 2017-07-15 09:30:00 CST): The system is going down for reboot at Sun 2017-07-16 05:30:00 CST! ^C[1]+ Done shutdown -r 05:30[root@localhost tmp]# shutdown -c Broadcast message from [email protected] (Sat 2017-07-15 09:31:03 CST): The system shutdown has been cancelled at Sat 2017-07-15 09:32:03 CST!
三 其他關(guān)機(jī)命令
haltinit 0poweroff
四 其他重啟命令
rebootinit 6
五 系統(tǒng)運(yùn)行級(jí)別
六 查看系統(tǒng)運(yùn)行級(jí)別以及修改系統(tǒng)的默認(rèn)級(jí)別
runlevelcat /etc/inittab
七 登出
logout
八 實(shí)戰(zhàn)
[root@localhost tmp]# [root@localhost tmp]# runlevelN 5[root@localhost tmp]# init 3PolicyKit daemon disconnected from the bus.We are no longer a registered authentication agent.[root@localhost tmp]# runlevel5 3[root@localhost tmp]# logout
如有疑問(wèn)請(qǐng)留言或者到本站社區(qū)交流討論,以上就是Linux 中關(guān)機(jī)重啟的命令詳解,感謝閱讀,希望能幫助到大家,謝謝大家對(duì)本站的支持!
新聞熱點(diǎn)
疑難解答
圖片精選