Linux-关机命令


关机命令

shutdown [OPTION]... TIME [MESSAGE]

shutdown 选项+时间+信息

常见的关机命令有

shutdown -a ===>使用/etc/shutdown.allow 来验证身份

shutdown -t  ===>t表示time 后面一般会接时间(s秒),表示多久之后,在发送kill信号

shutdown -r  ===> r表示reboot,重启

shutdown -h ===> h表示halted停机。

shutdown -c ===> c表示cancels ,取消shutdown操作

shutdown -h 20:30 'This system will shutdown,please save your file'

表示在20:30关闭系统并提示告诉所有用户,这个系统将关闭,请保存你的文件。

1 [root@VM_0_3_centos ~]# shutdown -h 20:30 'This system will shutdown,please save your file.'
2 
3 Broadcast message from root@VM_0_3_centos
4     (/dev/pts/0) at 19:47 ...
5 
6 The system is going down for halt in 43 minutes!
7 This system will shutdown,please save your file. 

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM