twhiting9275 Posted December 27, 2016 Share Posted December 27, 2016 The cron is a separate file, outside of the main WHMCs script . Docs here 0 Quote Link to comment Share on other sites More sharing options...
epimazzo Posted January 2, 2017 Share Posted January 2, 2017 Hi there, I followed Chris tip and also had a chat with Hostgator. Everything seems to be fine correctly setup but system LOG states that cron job never completes. It starts running but never ends as expected. I do not get any email as I used before the update to V7. Actually everything has been working fine until the upgrade comes out. I use: /opt/php56/bin/php-q /home/username/public_html/path-to-whmcs/crons/cron.php my config.php is pointing to this folder and the configuration one is right set to the whmcs root as expected. My cPanel is set just like that above either. Any idea why I'm still facing such behaviour? Thanks folks, 0 Quote Link to comment Share on other sites More sharing options...
WHMCS ChrisD Posted January 2, 2017 Share Posted January 2, 2017 Hey Epimazzo, Can you try running the following from your shell terminal WHMCS v7.1: /opt/php56/bin/php-q /home/username/public_html/path-to-whmcs/crons/cron.php -vvv WHMCS v7 /opt/php56/bin/php-q /home/username/public_html/path-to-whmcs/crons/cron.php -debug 0 Quote Link to comment Share on other sites More sharing options...
epimazzo Posted January 3, 2017 Share Posted January 3, 2017 Hi Chris, Thanks for the heads up I got an WHMCS email this time aroud the right time 4AM I had set earlier in Dash but with the following error: /bin/sh: /opt/php56/bin/php-q: No such file or directory Do you know what's going on? thanks Hey Epimazzo, Can you try running the following from your shell terminal WHMCS v7.1: WHMCS v7 - - - Updated - - - Chris, Can't actually run directly in my shell terminal as I do not have access and permissionto do so. We're a Hostgator reseller and run a shared server. We do not have rights to do it or get access on the server shell unfortunately. :-( 0 Quote Link to comment Share on other sites More sharing options...
stefan1959 Posted January 3, 2017 Share Posted January 3, 2017 (edited) I'm useing hostgator and this works /opt/php56/bin/php -q /home/{user}/crons/cron.php fine, you sure your cron is in the right directory? I put mine outside the public area, default is not. Check the docs for more info. UPDATE: I just reread the post, u seem to have it all correct, what your permissions on the cron folder? Also make sure in your cron line you havnt't added any spaces incorrectly, that may give that error. Steve Edited January 3, 2017 by stefan1959 0 Quote Link to comment Share on other sites More sharing options...
epimazzo Posted January 3, 2017 Share Posted January 3, 2017 Hi Steve, Thanks for your tip. I checked everything and seems to be fine with the permissions. Set to 755. Also, no spaces. I'll keep my eyes on it and follow searching.. 0 Quote Link to comment Share on other sites More sharing options...
stefan1959 Posted January 4, 2017 Share Posted January 4, 2017 Hi Steve,Thanks for your tip. I checked everything and seems to be fine with the permissions. Set to 755. Also, no spaces. I'll keep my eyes on it and follow searching.. Weird, I guess you have read this page. http://support.hostgator.com/articles/cpanel/what-do-i-put-for-the-cron-job-command you could try a different php version Steve 0 Quote Link to comment Share on other sites More sharing options...
epimazzo Posted January 5, 2017 Share Posted January 5, 2017 Hi Steve, I had made a few changes and now the Cron Daemon email I got states the following: /bin/sh: /opt/php56/lib/php: is a directory Do yo know if is it ok from a Cron Daemon perspective? Despite of this, I still get an alert in WHMCS Dash regarding the CRon job not working. Geezzzz...... 0 Quote Link to comment Share on other sites More sharing options...
EduPerea737 Posted January 12, 2017 Share Posted January 12, 2017 It worked for me. But Now I recieve this message: ================= Your WHMCS is configured to perform the Daily System Cron during the hour of 1 pm. However, the Daily System Cron did not execute within that hour as expected. This may be due to the scheduled time specified in your web hosting control panel's cron entry. Please ensure your web hosting control panel executes the WHMCS System Cron (cron.php) at least once during the hour of 1 pm. If you have confirmed that setting, and you continue to receive this message, then please refer to the WHMCS Cron documentation to ensure you have itemized the appropriate command and any additional options. Please contact WHMCS Support if you require further assistance. =============== 0 Quote Link to comment Share on other sites More sharing options...
bpotter Posted March 28, 2017 Share Posted March 28, 2017 Hi all, I had a mistake on my cron line. Following Chris suggestion and Hostgator information, finally I managed to get the cron work with this: /opt/php56/bin/php -q /home/[username]/public_html/[whmcs_folder]/crons/cron.php For those hosting on Hostgator and using WHMCS 7, this is the solution for the cron task issue. You need to append /opt/php56/bin/ to the cron in order to force the it to use the right PHP and ionCube versions. Thank you Chris for your advice. This did it for me. Thank you! 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.