Hi
Trying to run magento 2.2.6 on cpanel
i got 500 Internal Server Error
host: godaddy web hosting
any solution?
Solved! Go to Solution.
Hello @hussein_alamoodi
Try to remove the .htaccess file from your Magento root folder and then try to load your website in the browser.
If it doesn't give 500 internal server error after removing the .htaccess file, then there must be some PHP version issue or any server configuration is missing.
Hello @hussein_alamoodi
Try to remove the .htaccess file from your Magento root folder and then try to load your website in the browser.
If it doesn't give 500 internal server error after removing the .htaccess file, then there must be some PHP version issue or any server configuration is missing.
Hello @hussein_alamoodi
There are 4 ways for you to fix 500 internal server errors in Magento 2
500 internal server errors appear when logging to admin panel, so to solve it, you need to change permission of index.php file in root from 664 to 644.
Additionally, another index.php file in downloader/index.php should be changed permission to 644 to avoid error when navigating to System> Magento Connect> Magento Connect Manager.
If seeing 500 errors in specific pages like checkout page or product page, it means your server lacks of resource for running Magento. So you need to expand memory for your server.
<IfModule mod_php5.c> Php_value memory_limit 256M </IfModule>
memory_limit = 256M
Wrong settings in .htaccess file can cause error. In this case, you should try renaming/removing .htaccessfile.
The maintenance mode may cause changing file permission of index.php to 666 and make it appear error as web browsers is able to execute.
Do as follows to disable maintenance mode:
Hello @hussein_alamoodi,
Please run below command in magento 2 root directory
Static content deploy
php bin/magento cache:clean php bin/magento cache:flush php bin/magento setup:upgrade rm -rf pub/static/frontend/* pub/static/adminhtml/* var/cache/ var/generation/ var/page_cache/ var/view_preprocessed/ var/composer_home generated/ php -dmemory_limit=6G bin/magento setup:static-content:deploy -f chmod -Rf 777 pub/ var/ php bin/magento cache:clean
Apply permission
find . -type f -exec chmod 644 {} \; find . -type d -exec chmod 755 {} \; find ./var -type d -exec chmod 777 {} \; find ./pub/media -type d -exec chmod 777 {} \; find ./pub/static -type d -exec chmod 777 {} \; chmod 777 ./app/etc chmod 644 ./app/etc/*.xml
--
If my answer is useful, please Accept as Solution & give Kudos
ty guys
i just found out my php vr. was 7.2
and the 2.2.6 maximum support 7.1.99
In my previous reply, I told you that it could be the PHP version issue.
You can mark it as a solution so that it can help others who came to find the answer.
i have the same issue , we updated Magento from 2.2.3 to 2.2.6. then the error started, we changed the PHP to 7 from 7.1 but we still have the same issue.
my frustration is that the hosting company for 2 weeks not sure about the issue.
is it wise to keep Magento 2.2.6 or downgrade?
is it safe to work on the development site while we trying to solve the issue?
is it wise to download the site on a local server and work on it then upload to the live site when issue resolved?
Thanks all
Hello @alaa_hussain
It might be possible that you have a permission issue in your index.php file.
Run the following command from the root folder of your Magento and then check.
chmod 644 -R index.php
You can run the above command using sudo also if required.
sudo chmod 644 -R index.php
work for me, thanks!
@Mayur Bhuva wrote:Hello @hussein_alamoodi
Try to remove the .htaccess file from your Magento root folder and then try to load your website in the browser.
If it doesn't give 500 internal server error after removing the .htaccess file, then there must be some PHP version issue or any server configuration is missing.
It works for me this solution!