1. yum install crontabs
2. crontab -e
* * * * * flock -xn <lock-file1-path>/<lock-file1-name>.lock -c "sh <shell-file1-path>/<shell-file1-name>.sh"
* * * * * sleep 10 flock -xn <lock-file2-path>/<lock-file2-name>.lock -c "sh <shell-file2-path>/<shell-file2-name>.sh"
3. crontab -l
4. systemctl start/stop/restart crond
5. systemctl reload crond
来源:CSDN
作者:Neil_001
链接:https://blog.csdn.net/Neil_001/article/details/104002756