3

I'm getting an interesting issue. The frontend of my website loads fine, however when I try to navigate to:

domain.com/index.php/admin

I get a white page. I have enabled debugging mode and it displays this error:

Array
(
    [type] => 2
    [message] => include(): Failed opening '/var/www/vhosts/domain.co.uk/sub-domain.domain.co.uk/includes/src/__adminhtml.php' for inclusion (include_path='/var/www/vhosts/domain.co.uk/sub-domain.domain.co.uk/includes/src:.:')
    [file] => /var/www/vhosts/domain.co.uk/sub-domain.domain.co.uk/includes/src/Varien_Autoload.php
    [line] => 108
)

What's also interesting is that the file it's referencing (__adminhtml.php) doesn't exist in that directory:

Missing File

Any suggestions here?

Much appreciated.

2

Disable the compiler.

Edit includes/config.php

And comment out the two highlighted lines like shown here:

* EDIT *


Edit .htaccess file in the root of your installation of Magento and enable Developer mode. Add this at the end of the file:

ini_set('display_errors', 1);

Also, edit index.php and uncomment #ini_set('display_errors', 1);.

This should show an error instead of a WSOD (White Screen Of Death). If it doesn't check var/log/ and view the contents of exception.log or system.log. If nothing is relevant there, then proceed to look into your web server's error logs.

With that said however, the fact that the fatal exception has the path includes/src/ in it means that the Compiler is enabled and is trying to include a file that doesn't exist.

If you can SSH into your server give this a try, simply change into the directory of your magento installation:

NOTE: If you do not have SSH access simply renaming the includes to something else like includes.unused will work via FTP.

Check current compilation status

php -f shell/compiler.php -- state

Which should output something like:

Compiler Status:          Enabled
Compilation State:        Compiled
Collected Files Count:    6042
Compiled Scopes Count:    4

To Disable Magento compilation

php -f shell/compiler.php -- disable

Which should output something like:

Compiler include path disabled

To Clear all compiled files

php -f shell/compiler.php -- clear

Which should output something like:

Compilation successfully cleared

Ensure that compiler is disabled now by checking its status

php -f shell/compiler.php -- state

Which should output something like:

Compiler Status:                  Disabled
Compilation State:                Not
Compiled Collected Files Count:   0 
Compiled Scopes Count:            0

After confirming your compiler is disabled, remove the entire contents of the /var/cache/ folder with: rm -Rf var/cache/.

If you are not using files for caching (check your app/etc/local.xml file for details on what caching mechanism is being used) then restarting Redis, memcache, etc. may help flush any cached data for the compiler. You can also revert it to the file system by commenting out any cache nodes for an alternative caching system like Redis, memcache, DB, etc.

  • Thanks for the suggestion. But after disabling the compiler and opening the config.php file, those two lines of code are already commented out. – Charlie Coplestone Nov 22 '15 at 13:36
  • Interestingly enough, I've managed to get the file back via clearing/disabling/compiling the compiler. I'm now however getting this issue: Array ( [type] => 64 [message] => Cannot redeclare class Mage_Admin_Model_Session [file] => /var/www/vhosts/domain.co.uk/sub-domain.co.uk/includes/src/__adminhtml.php [line] => 504 ) – Charlie Coplestone Nov 22 '15 at 13:55
  • Since finding this new error, I've tried to comment/remove every class that it cannot redeclare, one by one.. Only to find that by the time I've commented them all out and refreshed the admin page, it gives no error whatsoever. Just a white page. – Charlie Coplestone Nov 22 '15 at 14:39
  • Updated Answer. – B00MER Nov 22 '15 at 20:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.