如何在Amazon Linux AMI上设置cron作业 [英] How to setup cron job on Amazon Linux AMI

查看:93
本文介绍了如何在Amazon Linux AMI上设置cron作业的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在托管

Amazon Linux AMI

要自动更新供稿,我必须运行以下cron作业.

To update the feed automatically I have to run following cron job.

参考 http://tt-rss.org/redmine/projects/tt-rss /wiki/UpdatingFeeds

*/30 * * * */usr/bin/php/var/www/html/tt-rss/update.php --feeds --quiet

*/30 * * * * /usr/bin/php /var/www/html/tt-rss/update.php --feeds --quiet

这是我所做的步骤:

  1. sudo su
  2. cd/etc
  3. crontab -e
  4. 添加此行 */30 * * * */usr/bin/php/var/www/html/tt-rss/update.php --feeds --quiet
  1. sudo su
  2. cd /etc
  3. crontab -e
  4. add this line */30 * * * * /usr/bin/php /var/www/html/tt-rss/update.php --feeds --quiet

但是我仍然收到消息更新守护程序未运行".

But I still got the message "Update Daemon is not running".

我可以知道这对cron工作是正确的步骤吗?

May I know is this correct step for cron job?

我的第一次设置.

谢谢, 亚历克斯

推荐答案

您应该首先检查cron日志文件/var/log/cron,并查找任何错误.这可能会给您答案.另外,请确保可以在命令行(/usr/bin/php /var/www/html/tt-rss/update.php --feeds --quiet)上成功运行命令.

You should first inspect the cron log file /var/log/cron and look for any errors. This will probably give you the answer. Also make sure you can run the command successfully on the command line (/usr/bin/php /var/www/html/tt-rss/update.php --feeds --quiet).

这篇关于如何在Amazon Linux AMI上设置cron作业的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆