Crons don't work

megakilobit

New Member
Messages
2
Reaction score
0
Points
0
Hi,

My cron just doesn't work. Here is the command line:
Code:
"/usr/bin/php /home/mkbit/www/ff_stats/analyse/analyse.php"

And the result:
Code:
/bin/sh: /usr/bin/php /home/mkbit/www/ff_stats/analyse/analyse.php: No such file or directory

WTF? Thx.
 

xav0989

Community Public Relation
Community Support
Messages
4,467
Reaction score
95
Points
0
try using 'public_html' instead of 'www'
then call 'php' instead of '/usr/bin/php'
 

descalzo

Grim Squeaker
Community Support
Messages
9,373
Reaction score
326
Points
83
Code:
/usr/local/bin/php   /home/mkbit/www/ff_stats/analyse/analyse.php

Do not put in quotes.
Make sure /ff_stats/analyse/analyse.php is the correct path.
Try running it from yoursite.com/ff_stats/analyse/analyse.php
 

xPlozion

New Member
Messages
868
Reaction score
1
Points
0
actually, a few months back (don't know if it still applies today), but i was told by a staff member here to use php-cron instead of the standard php binary...

so you would want to use
Code:
php-cron /home/mkbit/public_html/ff_stats/analyse/analyse.phpp

ps, www is just a symlink to public_html, so to avoid any possible problems, go w/ the absolute (real) path...
 

descalzo

Grim Squeaker
Community Support
Messages
9,373
Reaction score
326
Points
83
Which server are you on?

If you get it to work, please post here what the problem was. Several people have had problems getting cron jobs to work, yet nobody seems to come back to explain how they got them to work (if they did instead of just giving up).
 

alamar77

New Member
Messages
4
Reaction score
0
Points
0
Hello, i have the same problem... cron don't work...

my cron line is:

*/10 * * * 0,1,2,3,4,5 wget -O - http://www.mponline.org/xxxx/xxxx.php >> /home/alamar77/cronjobs/log2.log

I don't receive any email, and no error message...:dunno:
 
Last edited:

misson

Community Paragon
Community Support
Messages
2,572
Reaction score
72
Points
48
Hello, i have the same problem...
Actually, you don't. OP had extraneous quotes that caused the entire command line to be interpreted as a command name. Generally speaking, you should start a new thread unless you have the exact same problem and a thread doesn't include a resolution.

Test the command line by itself; you'll need to do this somewhere you have shell access (such as your own system).

Note you can specify a range of values using a hyphen:

Code:
*/10 * * * 0-5 ...

If you need more help, start a new thread.
 

alamar77

New Member
Messages
4
Reaction score
0
Points
0
Actually, you don't. OP had extraneous quotes that caused the entire command line to be interpreted as a command name. Generally speaking, you should start a new thread unless you have the exact same problem and a thread doesn't include a resolution.

Test the command line by itself; you'll need to do this somewhere you have shell access (such as your own system).

Note you can specify a range of values using a hyphen:

Code:
*/10 * * * 0-5 ...
If you need more help, start a new thread.

ok sorry... you are not able to help me, the line works perfectly on crontab on my pc... thanks... i start a new thread
 
Top