TinkPHP多店铺商城DSMall Linux下定时任务配置文档

crontab -e

# 执行频率:10分钟
*/10 * * * * /usr/local/php/bin/php -r "file_get_contents('http://xxx.com/crontab/Minutes/index.html');"
# 执行频率:1小时
0 */1 * * * /usr/local/php/bin/php -r "file_get_contents('http://xxx.com/crontab/Hour/index.html');"
# 执行频率:1天
0 3 * * * /usr/local/php/bin/php -r "file_get_contents('http://xxx.com/crontab/Date/index.html');"
# 执行频率:1个月
0 4 1 * * /usr/local/php/bin/php -r "file_get_contents('http://xxx.com/crontab/Month/index.html');"

可以查看定时任务记录

tail -f /var/log/cron

cat /var/log/cron

更多内容请关注官网:www.csdeshang.com

猜你喜欢

转载自blog.csdn.net/csdeshang/article/details/82185613