0

enter image description here

Here is the output. Not sure if cron isn't running or other issue. If I issue curl --silent http://..../scanner.php from terminal, I'm getting desired output. Actually scanner.php do some check and send an email. I've getting that. But not working from cron. Can you please advice me how can I detect the issue?

Edit: I have fixed the issue by adding a space before "&" and a new line after the command. Thanks all.

Thanks

IFightCode
  • 111
  • 2
  • 9

2 Answers2

1

Have a look in your logs in /var/log. If you grep them for CRON you should find messages from it, it normally logs successes and failures.

grep CRON /var/log/*

At a guess I'd ask whether your crontab file has a newline at the end. Without one the whole file normally fails.

cron requires that each entry in a crontab end in a newline character. If the last entry in a crontab is missing a newline (ie, terminated by EOF), cron will consider the crontab (at least partially) broken. A warning will be written to syslog.

Colin Newell
  • 254
  • 2
  • 6
-1

try wget using the following pattern

*/10 * * * * wget http:link.com/
Sukhjinder Singh
  • 1,994
  • 2
  • 9
  • 17