linux添加计划任务

crond 是linux用来定期执行程序的命令。当安装完成操作系统之后,默认便会启动此任务调度命令。crond命令每分锺会定期检查是否有要执行的工作,如果有要执行的工作便会自动执行该工作。可以用以下的方法启动、关闭这个服务:

[root@host ~]# /sbin/service crond start       启动
[root@host ~]# /sbin/service crond stop       关闭
Stopping crond:                                            [  OK  ]
[root@host ~]# /sbin/service crond start      启动
Starting crond:                                            [  OK  ]
[root@host ~]# /sbin/service crond restart   重新启动
Stopping crond:                                            [  OK  ]
Starting crond:                                            [  OK  ]

[root@host ~]# /sbin/service crond reload   重新载入配置
Reloading crond:                                           [  OK  ]

猜你喜欢

转载自www.cnblogs.com/playforever/p/9105398.html