linux 设置每天定时重启
linux-dash
A beautiful web dashboard for Linux
项目地址:https://gitcode.com/gh_mirrors/li/linux-dash

·
linux 设置定时重启
一、编辑cron
第一步,登陆账号
第二步,输入crontab -e
第三步,输入a进入编辑状态(或者按insert)
第四步,每天6点自动重启:0 6 * * * reboot
第五步,ctrl+c退出编辑状态
第六步,shift+:,然后输入wq
重启命令 service crond restart
0 2 * * * reboot ( 0 2表示每天凌晨两点重启.. 0 3表示凌晨3点..)
06 2 * * * reboot ( 06 2表示每天凌晨两点零六分重启.. 06 3表示凌晨3点零6分..)
0 4 * * * reboot ( 0 4表示每天凌晨四点重启.. 0 3表示凌晨3点..)
二.查看chkconfig --list
查看cron启动信息,如果2.3.4.5 项为off
则输入以下命令 chkconfig crond on




A beautiful web dashboard for Linux
最近提交(Master分支:5 个月前 )
186a802e
added ecosystem file for PM2 4 年前
5def40a3
Add host customization support for the NodeJS version 4 年前
更多推荐
所有评论(0)