I need to run php -q /home/myweb/public_html/check.php every 85 minutes (1 hour 25 minutes) so i added */25 */1 * * * php -q /home/myweb/public_html/check.php but it run on minute 25 and 50 every hours (based on /var/log/cron). please help
Set a cron to run every 1 minute: * * * * * /home/myweb/script.sh Create a shell script (note set the execute permission on this) script.sh: #!/bin/bash reftime=$(date -u -d "20100515" +%s) timenow=$(date -u -d "$(date -u +"%Y%m%d %H:%M")" +%s) if [ $(( ($timenow - $reftime) % 5100)) -eq 0 ] then php -q /home/myweb/public_html/check.php fi Code (markup): Or does the script allow you to run it faster e.g. once per hour, would be simpler if it did.
Why cant you just run it as: */85 * * * * php -q /home/myweb/public_html/check.php This should work fine afaik
You are right, it accepts only values 0-59 for minutes.. I think you will have to go for the solution you mentioned (via script)