运维网's Archiver
论坛
›
Shell/Powershell
› shell批量添加计划任务
ustbwang
发表于 2018-8-27 07:29:03
shell批量添加计划任务
#!/bin/bash
for i in `cat ./iplist.ini `
do
echo $i
scp ./MonitorProcess.sh $i:/home/haoren/
ssh $i "(echo '*/5 * * * * /home/haoren/MonitorProcess.sh' ;crontab -l) |crontab"
echo "Synchronization is complete."
done
页:
[1]
查看完整版本:
shell批量添加计划任务