Crontab每月定时任务的几个demo
发布于 分类 Linux
# crontab定时任务
# 分 时 日 月 星期 要执行的命令
# 每个月第一天
0 0 1 * * (shell script)
# 每个月最后一天
0 0 28-31 * * [ `date -d tomorrow +\%e` -eq 1 ] && (shell script)
# 每个月第一个星期6
0 0 1-7 * 6 (shell script)
参考与扩展阅读
http://changmingzhi.blog.51cto.com/10029613/1623737http://orionlin.pixnet.net/blog/post/69522303-%5Bcrontab%5D-%E6%AF%8F%E5%80%8B%E6%9C%88%E5%9B%BA%E5%AE%9A%E7%AC%AC%E4%B8%80%E5%80%8B%E6%98%9F%E6%9C%9Fx%E5%9F%B7%E8%A1%8C%E4%B8%80%E6%AC%A1
http://7056824.blog.51cto.com/69854/181784
-- The End --