Linux下定时重启Tomcat(修改)
linux-dash
A beautiful web dashboard for Linux
项目地址:https://gitcode.com/gh_mirrors/li/linux-dash

·
1.写一个shell脚本test.sh,重新启动tomcat
2.把test.sh文件放到root目录下
3.提高权限
chmod a+x test.sh
4.在控制台上输入以下命令
crontab -e
5.按i键编辑这个文本文件,输入以下内容,每天凌晨4:30重启tomcat
30 04 * * * /root/test.sh
按esc键退出编辑,输入wq回车保存
6.启动定时服务
[root@]# service crond stop
[root@]# service crond start




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)