首页 > 技术文章 > ubuntu 定时任务

huhuixin 2017-10-26 14:55 原文

使用的系统版本 ubuntu 16.04

lsb_release -a  查看系统版本

 

查看cron 运行状态  

service cron status;
编辑定时任务文件
vim testCrontab
(文件内容 : */1    *    *    *    *    date>>/home/hhx/cron.log)
添加文件到crontab
crontab testCrontab
查看定时任务
crontab -l
删除定时任务
crontab -r

 

推荐阅读