定时任务

查看定时任务状态

service crond status 

修改定时任务

crontab -e
service crond restart

例子

例子:
23 19 6 3 * /usr/bin/svn update /var/www/html --username xushenfeng --password ku2pCZ8aY3heu5zs --no-auth-cache > /var/www/html/update.log
3月6号19:23分更新
minute hour day month dayofweek command
minute - 从0到59的整数 
hour - 从0到23的整数 
day - 从1到31的整数 (必须是指定月份的有效日期)
month - 从1到12的整数 (或如Jan或Feb简写的月份)
dayofweek - 从0到7的整数,0或7用来描述周日 (或用Sun或Mon简写来表示)
command - 需要执行的命令(可用as ls /proc >> /tmp/proc或 执行自定义脚本的命令)

 

posted @ 2017-11-11 14:00  maxwell_xu  阅读(189)  评论(0编辑  收藏  举报