摘要: 脚本很简单,就下面几行: #!/bin/sh # c3h 为要检测的进程 process=`ps | grep c3h`; if [ "$process" == "" ]; then # 重启进程 /usr/bin/c3h 学号 密码 eth0.2 & echo "C3H restarted"; e 阅读全文
posted @ 2020-08-30 11:58 笠航 阅读(668) 评论(0) 推荐(0) 编辑
摘要: linux重启定时任务crontab命令 /etc/init.d/cron stop /etc/init.d/cron start /etc/init.d/cron restart 每天2点定时重启服务器 crontab -e,编辑定时任务文本 添加以下后ctrl+x,再按y退出 0 2 * * * 阅读全文
posted @ 2020-08-30 10:51 笠航 阅读(7116) 评论(0) 推荐(0) 编辑