prem101 Posted December 18, 2008 Share Posted December 18, 2008 (edited) Hello, Last week i changed my admin directory and made access to admin directory via a user password. Also in cron i specified the same admin directory. But after doing this the Mail Which used to coming Daily named WHMCS Cron JoB Activity Stopped. That mail was so important as this mail always used to mail me which invoices created on the day. How many accounts to be suspended and all lot of Info. According to that info i used to suspend accounts and all , As i dont store My WHM user pass in WHMCS due to security issue. This mail is so important to me. So can anyone tell how to set it up to work normally. Or is there anywhere else i can see what cron job did for the day. Thanx in Advance for a Positive Reply. Regards Edited December 18, 2008 by prem101 0 Quote Link to comment Share on other sites More sharing options...
bubbasheeko Posted December 19, 2008 Share Posted December 19, 2008 (edited) Hi Prem!, You say: Last week i changed my admin directory and made access to admin directory via a user password. Also in cron i specified the same admin directory. The problem is your .htaccess file. You have added authentication to the admin directory. The cron job can not get to the cron.php file because of the authentication in .htaccess. If you add this to your .htaccess file you should find a resolution to your problem: <Files "cron.php"> Allow from All Satisfy Any </Files> Hope this helps! Oh...also make sure that you have updated the cron job to correspond with the change to the admin directory name. Edited December 19, 2008 by bubbasheeko addition about the update to the cron. 0 Quote Link to comment Share on other sites More sharing options...
prem101 Posted December 19, 2008 Author Share Posted December 19, 2008 Thanx For Reply. But the thing is Cron is running ok and invoices getting generated Daily. Only thing is i dont get the mail named "WHMCS Cron Job Activity" Which used to Come Daily Before 5 Days. I Added your suggested code in .htaccess but still no luck. Let me know how can i get back that Email Daily. Regards 0 Quote Link to comment Share on other sites More sharing options...
bubbasheeko Posted December 20, 2008 Share Posted December 20, 2008 (edited) In that case...I am experiencing the same issue. It doesn't always send the email generated by the cron after the update has completed. I got it the first day I set it up and I haven't received it since. So I have added: php_value max_execution_time 400 php_value memory_limit 64M to my .htaccess file in my whmcs directory. I ran cron.php by manually browsing to the file and it triggered my activity email. By adding the max execution time to 400 it will allow for more time to complete the cron script. I also added the memory limit and set it to 64 M to ensure it was not a memory issue. Edited December 20, 2008 by bubbasheeko 0 Quote Link to comment Share on other sites More sharing options...
prem101 Posted December 20, 2008 Author Share Posted December 20, 2008 After Adding these Lines I get Internel Server Error. Kindly Suggest Also Suggest Me if i dont get that Mail. Where can i find Overdue Accounts so i can Manually Suspend Them. Thanx !!! 0 Quote Link to comment Share on other sites More sharing options...
bubbasheeko Posted December 20, 2008 Share Posted December 20, 2008 hi prem, Was there a number attached to that server error - ie. 500 - Internal Server Error? As for the second question. You can see overdue accounts under the WHMCS Admin Summary section (the first screen you see when you log in) - Invoices - Overdue. If you click on the overdue link it brings you to the overdue invoices. 0 Quote Link to comment Share on other sites More sharing options...
prem101 Posted December 21, 2008 Author Share Posted December 21, 2008 Below Is The Error : Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request. -------------------------------------------------------------------------------- Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.8b mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at Port 80 0 Quote Link to comment Share on other sites More sharing options...
bubbasheeko Posted December 21, 2008 Share Posted December 21, 2008 Prem101, can you post your .htaccess file contents so we can see what you have in there? 0 Quote Link to comment Share on other sites More sharing options...
prem101 Posted December 21, 2008 Author Share Posted December 21, 2008 Below are the .htaccess contents : AuthType Basic AuthUserFile "/home/hostindi/.htpasswds/public_html/billing/whmcsadmin/passwd" require valid-user <Files "cron.php"> Allow from All Satisfy Any </Files> php_value max_execution_time 400 php_value memory_limit 64M 0 Quote Link to comment Share on other sites More sharing options...
bubbasheeko Posted December 21, 2008 Share Posted December 21, 2008 Try removing the php_value's that I gave you from the .htaccess. Create a file called php.ini in the same directory as your .htaccess file. Your host most likely does not allow for the php_values in your .htaccess file. Add the following to the newly created php.ini file: max_execution_time 400 memory_limit 64M 0 Quote Link to comment Share on other sites More sharing options...
prem101 Posted December 21, 2008 Author Share Posted December 21, 2008 New Error when i run cron manually in browser : Site error: the file /home/hostindi/public_html/billing/whmcsadmin/cron.php requires the ionCube PHP Loader ioncube_loader_lin_5.2.so to be installed by the site administrator. But ioncube loaders are installed on server. Regards 0 Quote Link to comment Share on other sites More sharing options...
bubbasheeko Posted December 21, 2008 Share Posted December 21, 2008 Hi Prem101, Hmm...did you upload the included ioncube directory that came with the whmcs package to your server? 0 Quote Link to comment Share on other sites More sharing options...
prem101 Posted December 22, 2008 Author Share Posted December 22, 2008 Yes it is there and when i go to file ioncube-encoded-file.php in ioncube directory. I Get Message : This file has been successfully decoded. ionCube Loaders are correctly installed. Regards 0 Quote Link to comment Share on other sites More sharing options...
othellotech Posted December 22, 2008 Share Posted December 22, 2008 we had to have in our php.ini max_execution_time 1200 memory_limit 80M 0 Quote Link to comment Share on other sites More sharing options...
prem101 Posted December 22, 2008 Author Share Posted December 22, 2008 Still i get : Site error: the file /home/hostindi/public_html/billing/whmcsadmin/index.php requires the ionCube PHP Loader ioncube_loader_lin_5.2.so to be installed by the site administrator 0 Quote Link to comment Share on other sites More sharing options...
bubbasheeko Posted December 29, 2008 Share Posted December 29, 2008 Hi Prem, Check your php.ini file if you have access to it. Make sure the paths below are what are in the php.ini file. zend_extension=/home2/sitename/public_html/ioncube/ioncube_loader_lin_5.2.so zend_extension_ts=/home2/sitename/public_html/ioncube/ioncube_loader_lin_5.2_ts.so 0 Quote Link to comment Share on other sites More sharing options...
Shimmy Posted January 5, 2009 Share Posted January 5, 2009 My cron email and database backup stopped working on December 29. It's still generating invoices, but I can't really tell if it's doing everything else. Anyone have any suggestions? 0 Quote Link to comment Share on other sites More sharing options...
sparky Posted January 6, 2009 Share Posted January 6, 2009 cPanel did an update and changed the permission of the cron file. I had to go in and change mine as soon as I realised. If you log into your cPanel and click on cron it incorrect it will give you a message there to change perms to 4755 0 Quote Link to comment Share on other sites More sharing options...
LeMarque Posted January 6, 2009 Share Posted January 6, 2009 (edited) //edit this occurred after I added <Files "cron.php"> Allow from All Satisfy Any </Files> to .htaccess removing those lines eliminated the error in the shell but I still don't get backups //end edit Similar problem in that my backups stopped working - when I run php -q /home/nmd/public_html/domains/admin/cron.php/ from the shell I get : Could not open input file: /home/xxx/public_html/xxxxx/admin/cron.php/ Edited January 6, 2009 by LeMarque 0 Quote Link to comment Share on other sites More sharing options...
arhost Posted January 6, 2009 Share Posted January 6, 2009 Try this: php -q /home/nmd/public_html/domains/admin/cron.php 0 Quote Link to comment Share on other sites More sharing options...
LeMarque Posted January 7, 2009 Share Posted January 7, 2009 arhost - that was a copy and paste error - also, I corrected the .htaccess and I do see "Credit Card Payments Processed" in my activity log about the time I ran it from the shell. We'll see if the backup runs at 3:AM This all started after the 3.8.1 upgrade. 0 Quote Link to comment Share on other sites More sharing options...
Shimmy Posted January 7, 2009 Share Posted January 7, 2009 (edited) cPanel did an update and changed the permission of the cron file.I had to go in and change mine as soon as I realised. If you log into your cPanel and click on cron it incorrect it will give you a message there to change perms to 4755 I did that and it still isn't sent. The system is still sending invoices, but the cron isn't being shown in the Activity Log as being run since December 29 (the day I upgraded to 3.8.1). Edited January 7, 2009 by Shimmy 0 Quote Link to comment Share on other sites More sharing options...
eugenevdm Posted May 18, 2009 Share Posted May 18, 2009 php_value max_execution_time 400 You saved my life. I have had this problem for about 9 months and couldn't for the life of me figure out why I don't get confirmation e-mails for the cron.php. When I eventually figured it cron.php works if you run it multiple times did I change the memory_limit value instead of the max_execution_time value. I also mistakenly changed the Apache httpd one instead of the PHP CLI one. On Ubuntu you should change /etc/php5/cli/php.ini instead of /etc/php5/apache2/php.ini. My system is now very stable with Ubuntu. Is there a way to change this on demand? Because I'm scared if I put it too long for other apps I might have to long for exit codes. But for now I am just very happy to have a confirmation e-mail again without having to manually run cron.php! Hurah! FYI: My cron.php runs about 80 minutes before completion. 0 Quote Link to comment Share on other sites More sharing options...
eugenevdm Posted May 24, 2009 Share Posted May 24, 2009 There are various ways to change it on demand such as creating a "stub" php file called cron_starter.php with ini_set('memory_limit', '256M'); ini_set('max_execution_time', '300'); require ('cron.php'); Got the tip above from here: http://forum.whmcs.com/showthread.php?t=16450&highlight=cron.php&page=2 This seems to be a good way to leave the php.ini value for PHP 5 on Ubuntu at default for max_execution_time which is 30 seconds, which I had to do on a shared server. 0 Quote Link to comment Share on other sites More sharing options...
hoobastank68 Posted August 10, 2009 Share Posted August 10, 2009 Hi, Is anyone else having the same issue still even after tweaking php.ini? We seem to receive the email some days, and not other days. 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.