Categories
Magento

Magento 500 Internal Server Error after turning on compilation

You received the “Magento 500 Internal Server Error” after turning on the compilation?

Then the following lines within the file “includes/config.php” need to be edited:

define(‘COMPILER_INCLUDE_PATH’, dirname(FILE).DIRECTORY_SEPARATOR.’src’); #define(‘COMPILER_COLLECT_PATH’, dirname(FILE).DIRECTORY_SEPARATOR.’stat’);

change the lines to:

#define(‘COMPILER_INCLUDE_PATH’, dirname(FILE).DIRECTORY_SEPARATOR.’src’); define(‘COMPILER_COLLECT_PATH’, dirname(FILE).DIRECTORY_SEPARATOR.’stat’);

The # character must be added to the first line and the # char from line 3 as shown in the example above need to be removed.

If you still can’t access your backend then most likely you need to clear and flush the cache of your magento site.
In case you are using redis then the redis cache also need to be flushed.

Clearing the local browser cache is also advised or using the incognito / private window.

Just to note: DON’T use the “Enable Compilation” button before running the compilation (“Run Compilation Process”).

Leave a Reply

Your email address will not be published. Required fields are marked *