Cron job not working within cwp

Started by pixelpadre, July 25, 2016, 11:09:33 PM

Previous topic - Next topic

pixelpadre

I am not having any luck with my cron jobs

*/15 * * * * /usr/local/php /home/username/public_html/usersite.com/oc-includes/osclass/cron.php >> /home/username/myfile.log

Any ideas what is wrong?

Administrator

you are not using the correct php path, you have the correct path in the cwp cron

Don't forget to always use a full path, eg. /usr/local/bin/php

pixelpadre

#2
I thought that meant the path to php.ini.

Log file for user says:

ABS_PATH is not loaded. Direct access is not allowed.  I guess you cant call cron.php directly.......

driftwood

If it helps at all this works for me;

5,20,35,50 * * * * wget -q -O - http://mysite.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1

Thats to call the wordpress cron instead of having it shoot via page loads.

hostuga

#4
Attention Correct Cron job.

I copied with no whmcs -> php -q /home/username/public_html/customers/admin/cron.php   
Attention, leave space eg.  php /Home   1 space.

cronjob Configured correctly      */5 * * * * /usr/local/bin/php /home/username/public_html/customers/admin/cron.php
Hello, I'm from Portugal, I'm loving the CentOs Web panel let's evolve this project, it's unique, and very useful. Sorry my english portugues :-)

digdug

and this is happen new version fresh install on centos 7
cron job cannot create