Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Page 1 of 2
Disabling the Magento compiler is not possible
 
EURO
Jr. Member
 
Total Posts:  23
Joined:  2009-02-26
 

I tried to enable the compiler on my 1.4 Magento installation by clicking “Enable” in the compiler configuration page in the back-end.

After this, Magento stopped working. I only get this error for every page in the front-end and back-end:

Warning: include_once(Mage_Core_functions.php) [function.include-once]: failed to open stream: No such file or directory in /domain/app/Mage.php on line 36

Warning: include_once() [function.include]: Failed opening ‘Mage_Core_functions.php’ for inclusion (include_path=’/domain/includes/src:.:/usr/local/lib/php’) in /domain/app/Mage.php on line 36

Warning: include_once(Varien_Autoload.php) [function.include-once]: failed to open stream: No such file or directory in /domain/app/Mage.php on line 37

Warning: include_once() [function.include]: Failed opening ‘Varien_Autoload.php’ for inclusion (include_path=’/domain/includes/src:.:/usr/local/lib/php’) in /domain/public_html/app/Mage.php on line 37

Fatal error: Class ‘Varien_Autoload’ not found in /domain/public_html/app/Mage.php on line 53

Now I want to disable the compiler so my website starts working again.

I found out I can disable the compiler from the shell with this command:
php /shell/compiler.php disable

But when I try this I get the next error:

Fatal error: Allowed memory size of 262144 bytes exhausted (tried to allocate 19456 bytes) in /domain/app/code/core/Mage/Compiler/Model/Process.php on line 287

But when I execute php -i | grep memory I get the this result: memory_limit => 128M => 128M. This is the same value as in my php.ini and .htaccess files. The memory limit in the given error is also very low, 262144 bytes are only 256 Kbytes. It is clear almost no code will run with such memory limit. I don’t think this memory limit is caused by my php configuration.

Is there any other way to disable the compiler or to fix compiler.php ??? I want to get my webshop up and running again.

 
Magento Community Magento Community
Magento Community
Magento Community
 
EURO
Jr. Member
 
Total Posts:  23
Joined:  2009-02-26
 

I got my shop running again.

/shell/compiler.php works only directly after the cache is emptied. When you run compiler.php once, it will fill the cache, so it will not run for a second time.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Vit design
Jr. Member
 
Total Posts:  5
Joined:  2009-09-19
 

Hello,

I have the same problem as you. I enabled Compiler and suddenly the site went all white. I don’t understand how you solved it. Please explain so I can’t misunderstand smile

 
Magento Community Magento Community
Magento Community
Magento Community
 
EURO
Jr. Member
 
Total Posts:  23
Joined:  2009-02-26
 

1. Empty the cache of your shop by deleting all files in the magentodir/var/cache directory.
2. Directly after emptying you can disable the compiler by running php magentodir/shell/compiler.php disable

 
Magento Community Magento Community
Magento Community
Magento Community
 
Senetor
Sr. Member
 
Avatar
Total Posts:  259
Joined:  2009-03-26
Denmark
 

2. Directly after emptying you can disable the compiler by running php magentodir/shell/compiler.php disable

HOW?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Paulus
Guru
 
Total Posts:  335
Joined:  2008-07-21
 
Senetor - 07 May 2010 01:12 PM

2. Directly after emptying you can disable the compiler by running php magentodir/shell/compiler.php disable


HOW?

You type this

php magentodir/shell/compiler.php disable

in your SSH program, such as Putty.

 
Magento Community Magento Community
Magento Community
Magento Community
 
social_queen
Jr. Member
 
Avatar
Total Posts:  14
Joined:  2010-09-27
 

THANK YOU!!
This saved my life!  cheese

 
Magento Community Magento Community
Magento Community
Magento Community
 
pansilu2001
Jr. Member
 
Total Posts:  2
Joined:  2010-03-15
 

Thankyo so, much. Solution works

 
Magento Community Magento Community
Magento Community
Magento Community
 
zumajimi
Jr. Member
 
Total Posts:  5
Joined:  2011-01-18
 

I don’t have an SSH access to run command “php magentodir/shell/compiler.php disable” .
Please I need some advice for another way around to do this.  Thanks.

 
Magento Community Magento Community
Magento Community
Magento Community
 
zumajimi
Jr. Member
 
Total Posts:  5
Joined:  2011-01-18
 

Well I got it working now. My site comes back on now.  Thanks for the solution.  Works perfectly well.  Finally, I was able to manage this without an SSH access by creating a new class copied from class ‘Mage_Shell_Compiler’ and also override ‘protected function _validate()’ .  If I didn’t override this function, it wouldn’t let me run the code.  It said ‘This script cannot be run from Browser. This is the shell script.’

 
Magento Community Magento Community
Magento Community
Magento Community
 
mcweb
Jr. Member
 
Total Posts:  1
Joined:  2011-07-29
 

when i run
php -f compiler.php help
i geht this error message:
Uncaught exception ‘Zend_Db_Adapter_Exception’ with message ‘The PDO extension is required for this adapter but the extension is not loaded’

I also can not run php compiler.php disable as it leads to this error:

Fatal error: Uncaught exception ‘Zend_Db_Adapter_Exception’ with message ‘The PDO extension is required for this adapter but the extension is not loaded’ in /home/bettenland/public_html/shop/lib/Zend/Db/Adapter/Pdo/Abstract.php:342
Stack trace:
#0 /public_html/shop/lib/Zend/Db/Adapter/Abstract.php(247): Zend_Db_Adapter_Pdo_Abstract->setFetchMode(2)
#1 /public_html/shop/app/code/core/Mage/Core/Model/Resource/Type/Db/Pdo/Mysql.php(60): Zend_Db_Adapter_Abstract->__construct(Array)
#2 /public_html/shop/app/code/core/Mage/Core/Model/Resource/Type/Db/Pdo/Mysql.ph p(42): Mage_Core_Model_Resource_Type_Db_Pdo_Mysql->_getDbAdapterInstance(Array)
#3 /public_html/shop/app/code/core/Mage/Core/Model/Resource.php(93): Mage_Core_M odel_Resource_Type_Db_Pdo_Mysql->getConnection(Object(Mage_Core_Model_Config_Element))
#4 /public_html/shop/app/code/core/Mage/Core/Model/Mysql4/Abstract.php(297): Mag e_Core_Model_Resource->getConnection(’core_read’)
#5 /home/… in /public_html/shop/lib/Zend/Db/Adapter/Pdo/Abstract.php on l ine 342

 
Magento Community Magento Community
Magento Community
Magento Community
 
Simon Janssen
Jr. Member
 
Avatar
Total Posts:  5
Joined:  2011-05-02
Huissen, the Netherlands
 

I had this problem when trying to enable Magento’s compiler. The solution for me was to reinstall Magento’s PEAR library and Magento compiler in Magento Connect. I don’’t which of those modules fixed the issue but it worked for me

 
Magento Community Magento Community
Magento Community
Magento Community
 
h2hfabrics
Jr. Member
 
Total Posts:  1
Joined:  2011-12-29
 

I just reinstalled compiler in Magento Connect and it worked for me!

 
Magento Community Magento Community
Magento Community
Magento Community
 
shiwak224
Member
 
Total Posts:  41
Joined:  2011-03-23
 
h2hfabrics - 18 January 2012 09:33 PM

I just reinstalled compiler in Magento Connect and it worked for me!

How did u reinstall compiler? I have been trying to sort out this problem, but after disabling compiler.php the following error comes up

Fatal error: Call to undefined method Mage::getResourceHelper() in /home/pentljac/domains/pentlja.com/public_html/app/code/core/Mage/Core/Model/Resource/Db/Collection/Abstract.php on line 533
Does anyone got solution?

Or tell me how to reinstall compiler when i cant even go to magento connect as my admin for the same error..

 
Magento Community Magento Community
Magento Community
Magento Community
 
Simon Janssen
Jr. Member
 
Avatar
Total Posts:  5
Joined:  2011-05-02
Huissen, the Netherlands
 

You have to login to your Magento Connect Manager. The url is: www.yourdomainname.com/downloader

You should see a login page. Have you ever visited this page?

If you don’t see any page, the folder is either not present, or something is really wrong with your website......

Please let me know what happens....

 
Magento Community Magento Community
Magento Community
Magento Community
 
usauggs
Jr. Member
 
Total Posts:  26
Joined:  2009-08-23
 

Thanks a lot for your solution.

I heard that compilation could help your website run faster, so i tried to enable compilation, but it goes all white after enable button pressed.

i used “php magentodir/shell/compiler.php disable” and clear the var/cache directory, but there are errors telling me “cache not writable”, all right, the new cache directory needs “chmod -R o+w cache”,

after all this done, the site works again.

i go to the backend and press “run compilation process”, now the compiler is enable as it stated.

Hope this help. smile

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top
Page 1 of 2