Ebar Posted January 11, 2017 Share Posted January 11, 2017 So it seems WHMCS and PHP7 don't get along all that well, after having searched for similar problems. I'm getting the Internal Error 500 from Apache when trying to access basically any page inside my admin area, and select, seemingly random pages in the main directory. This is a brand new server, running Ubuntu 16.04 LTS, with a fresh install of Plesk Onyx and a fresh download/install of WHMCS 7.1.1. WHMCS installed flawlessly once I got the stupid ionCube PHP Loader installed. I went to login as admin. I accessed the admin login page just fine, logged in, and got hit with the Error 500. Turns out I can't access any pages in the admin folder. And I also get the 500 error when trying to access /announcements.php. All other links from the client area while not logged in, work just fine. I checked my Apache error log, and no errors have been logged for this. I even set the log sensitivity to "debug", just about as low as it goes, just in case. I checked all permissions and file/folder owners, there is no difference between the pages I can and cannot access. I also temporarily disabled my .htaccess. I've gone through this exact install process 2-3x before and haven't had any issues. However, I cannot recall if any of them were running php7. Possible they were all 5.6. From my phpinfo(), verifying ionCube is installed (that plus that fact that I installed just fine) "This program makes use of the Zend Scripting Language Engine: Zend Engine v3.0.0, Copyright © 1998-2016 Zend Technologies with the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured) v6.0.8, Copyright © 2002-2016, by ionCube Ltd. with Zend OPcache v7.0.8-0ubuntu0.16.04.3, Copyright © 1999-2016, by Zend Technologies" I am at an absolute loss as to what to do. 0 Quote Link to comment Share on other sites More sharing options...
twhiting9275 Posted January 11, 2017 Share Posted January 11, 2017 Apache 500s usually mean an issue with your server configuration in this case. WHMCS is pretty solid when it comes to 500 errors. Start by enabling error display. Since you can't access admin itself, you have to do this the MySQL way. In the database (phpmyadmin, or MySQL shell) UPDATE tblconfiguration SET value='on' WHERE setting= 'DisplayErrors' Then try viewing the pages again. This should (hopefully) give you some insight as to what the problem is If not, then take a look in the whmcs, and the admin folders for an error_log file. Go through that. Lastly, take a look through the server error_logs (apache), this may help you out as well. 0 Quote Link to comment Share on other sites More sharing options...
Ebar Posted January 12, 2017 Author Share Posted January 12, 2017 (edited) Alright so I managed to turn on errors in WHMCS. Had to do it in the configuration.php file and not the DB. Here is what I'm getting: -------- Fatal error: Uncaught PDOException: SQLSTATE[42000]: Syntax error or access violation: 1055 Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'db_whmcs.tbladminlog.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by in /var/www/vhosts/mydomain.com/httpdocs/vendor/illuminate/database/Connection.php:333 Stack trace: #0 /var/www/vhosts/mydomain.com/httpdocs/vendor/illuminate/database/Connection.php(333): PDO->prepare('select * from `...') #1 /var/www/vhosts/mydomain.com/httpdocs/vendor/illuminate/database/Connection.php(706): Illuminate\Database\Connection->Illuminate\Database\{closure}(Object(Illuminate\Database\MySqlConnection), 'select * from `...', Array) #2 /var/www/vhosts/mydomain.com/httpdocs/vendor/illuminate/database/Connection.php(669): Illuminate\Database\Connection->runQueryCallback('select * from `...', Array, Object(Closure)) #3 /var/www/vhosts/portal.so in /var/www/vhosts/mydomain.com/httpdocs/vendor/whmcs/whmcs-foundation/lib/Terminus.php on line 0 ------ Domain name in above error switched for privacy. Anyway I'm reasonably well versed in PHP, but my MySQL skills are limited to the point to where I have no idea where to start with this error. Edited January 12, 2017 by Ebar 0 Quote Link to comment Share on other sites More sharing options...
WHMCS ChrisD Posted January 12, 2017 Share Posted January 12, 2017 Hey Ebar, Could you try running the query SELECT @@sql_mode on your database and see what comes up with your database. 0 Quote Link to comment Share on other sites More sharing options...
Ebar Posted January 12, 2017 Author Share Posted January 12, 2017 Hi Chris, ONLY_FULL_GROUP_BY,NO_ZERO_IN_DATE,ERROR_FOR_DIVIS... is the result. 0 Quote Link to comment Share on other sites More sharing options...
WHMCS ChrisD Posted January 12, 2017 Share Posted January 12, 2017 Hi Chris, ONLY_FULL_GROUP_BY,NO_ZERO_IN_DATE,ERROR_FOR_DIVIS... is the result. Excellent, that shows the issue. You will need to remove the the SQL_MODE options as this is causing the issue. It is a new SQL mode, sometimes added by default that conflicts with some functions For more information on SQL Modes, and how to set the SQL Mode for your MySQL environment, please refer to MySQL's official documentation available at the url below. https://dev.mysql.com/doc/refman/5.0/en/sql-mode.html 0 Quote Link to comment Share on other sites More sharing options...
Ebar Posted January 12, 2017 Author Share Posted January 12, 2017 Awesome, I appreciate the speedy help! 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.