Hello,
I have a problem, when I give a mission for cron (execute a script php) makes it but at the end of some instant mission abolishes all alone.
Why? How to avoid it?
Thank you for your assistant.
Hello,
I have a problem, when I give a mission for cron (execute a script php) makes it but at the end of some instant mission abolishes all alone.
Why? How to avoid it?
Thank you for your assistant.
Could you please be a little more specific? Does the cron not run at all? Is there any errors?
This may also be of interest:
Note that if you have two crons there must still be at least five minutes in between them.
Consider these scenarios:
Originally Posted by Scenario 1
Scenario 1 would work, as they alternate every 5 minutes.Originally Posted by Scenario 2
Scenario 2 would NOT work, as cron 2 would attempt running only 2 minutes after cron 1 was run. This would result in both crons being removed. Same applies if you set one single cron to run more often then every 5 minutes.
Last edited by Anna; 02-08-2011 at 01:03 PM.
Do you have trouble reaching your site?
Check here first: News and Announcements
Don't forget that x10hosting has an irc server as well. Come and join the fun
server: irc.x10hosting.com, main channel: #x10hosting
There's a lot helpful users there if need help building your site
Remember, cron jobs have to be 5 minutes apart. The system will delete all your cron jobs if
a) any job runs more often than every 5 minutes
b) two jobs go off withing 5 minutes of each other, ie job1 runs on the hour and job2 runs every half hour at 0 and 30
If that is not the problem, try making your command line look like:
then you can see any output or errors in test_log.txtCode:/usr/bin/php /home/me/public_html/test.php >> /home/me/public_html/test_log.txt 2>&1
Nothing is always absolutely so.
Thank you for your answers.
Then, I have 2 spots cron, one updates the number of connected every 5 minutes.
And the other updates a number every hour.
In fact quite everything works very well, then suddenly nothing more does not put itself has in the daytime, I thus go to see my spots cron and they are not any more :/
Nevertheless there are no errors
Then you have to adjust your cron setup.
1. You can make it one job/script, every 5 minutes which combines the two scripts. Script always does job1 and checks the time to decide if it does job2.
2. If you do not mind having the 5 minute script skip once an hour,
0 * * * * HourlyJob
5,10,15,20,25,30,35,40,45,50,55 * * * * FiveMinuteJob
3. Combination of #1 and #2, adjust the Hourly job to include the tasks done by the FiveMinuteJob
#1 and #3 require that you know what your cron jobs do/PHP.
Nothing is always absolutely so.
Then we cannot have several spots for cron?
Nevertheless I respected rules.
It's a pity, I would try to group together my 2 spots.
In fact I am novice in this system of cron :p
Of the blow I found very practical that the host suggests programming the frequency an hour etc.
Thank you for your help.
you can have several spots, as long as there's no crons that run within 5 minutes of another.
Prime Membership, at $4.95 / year would allow the crons to run every minute, but not the basic free package
Do you have trouble reaching your site?
Check here first: News and Announcements
Don't forget that x10hosting has an irc server as well. Come and join the fun
server: irc.x10hosting.com, main channel: #x10hosting
There's a lot helpful users there if need help building your site
Ah yes, it is good, I understood
Thank you still for your answers.