Fatal error: Class 'Zend_Registry' not found in /var/www/clients/client9/web8/web/piwik_stats/core/Updates.php on line 34

I attempted to do an automatic update from 0.5.4 to 0.5.5 and received the following error:

Fatal error: Class 'Zend_Registry' not found in /var/www/clients/client9/web8/web/piwik_stats/core/Updates.php on line 34

I then attempted a manual upgrade. Same issue. I am unable to log into my piwik installation now, because this is the only thing that appears. Please assist me.

Thanks.

There’s no reference to Zend_Registry in core/Updates.php.

Sounds like a bad file … you say this was an auto-update? Hmm…

It was autoupdate initially. However, when I got the error, I redownloaded the latest.zip and uploaded everything again. I am still receiving the error.

Link:

http://www.team-vipers.com/piwik_stats/

My Updates.php looks like this. I agree with you though, I don’t see Zend_Registry.

<?php
/**
 * Piwik - Open source web analytics
 *
 * @link http://piwik.org
 * @license http://www.gnu.org/licenses/gpl-3.0.html Gpl v3 or later
 * @version $Id: Updates.php 1845 2010-02-14 02:33:00Z vipsoft $
 *
 * @category Piwik
 * @package Piwik
 */

/**
 * Abstract class for update scripts
 *
 * @example core/Updates/0.4.2.php
 * @package Piwik
 */
abstract class Piwik_Updates
{
    /**
     * Return SQL to be executed in this update
     *
     * @return array
     */
    static function getSql()
    {
        return array();
    }

    /**
     * Incremental version update
     */
    abstract static function update();
}

Take a look in Apache’s error.log. There might be more clues there.

The only thing I get is:

[Wed Mar 24 15:40:37 2010] [error] [client 12.2.142.12] PHP Fatal error:  Class 'Zend_Registry' not found in /var/www/clients/client9/web8/web/piwik_stats/core/Updates.php on line 34

Any other ideas? style_emoticons/<#EMO_DIR#>/unsure.gif

Help? I’m out of ideas.

The error suggests a problem with php or the config. What version of php are you running?

Can you increase your max memory limit for php? Can you pm the output from phpinfo()?

Have you tried to restart Apache or reboot the server?

[quote=vipsoft @ Mar 28 2010, 03:21 AM]The error suggests a problem with php or the config. What version of php are you running?

Can you increase your max memory limit for php? Can you pm the output from phpinfo()?

Have you tried to restart Apache or reboot the server?[/quote]

None of the php values have been changed.

PHP 5.3.1
Memory limit is at 128M
PM’d
Yes to both, though the restarts were not due to this problem.

I’m having the exact problem after attempting to upgrade from 0.5.4 to 0.5.5. I did a manual upgrade by FTPing all the files up then got this error so I went straight to the server, downloaded the zip file, and tried to replace the files that way but am still getting the error.

Fatal error: Class 'Zend_Registry' not found in /var/www/html/piwik/core/Updates.php on line 34
Call Stack
#    Time    Memory    Function    Location
1    0.0003    635520    {main}( )    ../index.php:0
2    0.0452    2160936    Piwik_FrontController->dispatch( )    ../index.php:104
3    0.0467    2190568    call_user_func_array ( )    ../FrontController.php:129
4    0.0467    2190816    Piwik_CoreUpdater_Controller->index( )    ../FrontController.php:0
5    0.0467    2191008    Piwik_CoreUpdater_Controller->runUpdaterAndExit( )    ../Controller.php:196
6    0.0532    2348776    Piwik_Updater->getSqlQueriesToExecute( )    ../Controller.php:230
7    0.0533    2352752    require_once( '/var/www/html/piwik/core/Updates/0.5.5.php' )    ../Updater.php:116
8    0.0533    2353048    Piwik_Loader::autoload( )    ../Loader.php:0
9    0.0536    2366904    Piwik_ErrorHandler( )    ../ErrorHandler.php:0

Don’t know that this will help, but for an unrelated reason I have forensic logging enabled on the Apache server.

+3759:4baf7da7:49|GET /piwik/ HTTP/1.1|Host:192.168.x.x|User-Agent:Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv%3a1.9.2.2) Gecko/20100316 Firefox/3.6.2|Accept:text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8|Accept-Language:en-us,en;q=0.5|Accept-Encoding:gzip,deflate|Accept-Charset:ISO-8859-1,utf-8;q=0.7,*;q=0.7|Keep-Alive:115|Connection:keep-alive
-3759:4baf7da7:49
+3756:4baf7da7:48|GET /piwik/index.php?module=CoreUpdater HTTP/1.1|Host:192.168.x.x|User-Agent:Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv%3a1.9.2.2) Gecko/20100316 Firefox/3.6.2|Accept:text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8|Accept-Language:en-us,en;q=0.5|Accept-Encoding:gzip,deflate|Accept-Charset:ISO-8859-1,utf-8;q=0.7,*;q=0.7|Keep-Alive:115|Connection:keep-alive|Cookie:PIWIK_SESSID=3suns39povl0v4juv8adt3rfk7
-3756:4baf7da7:48

PHP 5.3.2
Memory Limit 256MB

I have not changed any configuration in PHP for at least 6 months now. I cannot reboot the server ATM but I did restart the Apache service and am still getting this error.

I will PM my phpinfo as well, maybe there is a common thread.

Thanks,
Dan

Thank you for both sending me your phpinfo.

What you have in common is running php 5.3.x on what appears to be an fc kernel x86_64.

To further isolate the cause, please try disabling eaccelerator, putting

php_flag eaccelerator.enable 0
php_flag eaccelerator.optimizer 0

in a .htaccess file in the document root.

[quote=vipsoft @ Mar 28 2010, 05:09 PM]Thank you for both sending me your phpinfo.

What you have in common is running php 5.3.x on what appears to be an fc kernel x86_64.

To further isolate the cause, please try disabling eaccelerator, putting

php_flag eaccelerator.enable 0
php_flag eaccelerator.optimizer 0

in a .htaccess file in the document root.[/quote]

That made no change for me. I tried it in the document root and only in piwik’s directory.

That fixed it for me!!! My spec:

Fedora 12 x86_64
Apache 2.2.14
PHP 5.3.2
MySQL 5.1.44

Thanks!

Mosquito: Apache may not be reading your .htaccess file if AllowOverride is none. If that’s the case, you’ll have to disable eAccelerator via your Apache config file.

vip - I’ve added the command directly to the apache config file and restarted Apache. Still no change. style_emoticons/<#EMO_DIR#>/sad.gif

The only difference in specs compared to what dan posted is that I have PHP 5.3.1

Edit: Just updated to 5.3.2. No change. style_emoticons/<#EMO_DIR#>/sad.gif Now I’m just confused.

Mosquito: try disabling it globally though PHP’s configs. Open up /etc/php.d/eaccelerator.ini and change the “eaccelerator.enable” and “eaccelerator.optimizer” values to 0 then restart Apache.

That worked. Thank you style_emoticons/<#EMO_DIR#>/smile.gif

On another happy note, despite the error I’ve been receiving for the past several days, it does not appear that I missed any visits. That is a nice little surprise.

[quote=Mosquito @ Mar 30 2010, 08:55 AM]That worked. Thank you style_emoticons/<#EMO_DIR#>/smile.gif

On another happy note, despite the error I’ve been receiving for the past several days, it does not appear that I missed any visits. That is a nice little surprise.[/quote]

Glad that fixed it for you!

The question now becomes, why does the eaccelerator break it? style_emoticons/<#EMO_DIR#>/dry.gif

Evidently, there’s a bug in eAccelerator. (MacOS MAMP users have encountered a similar problem in the past.) I didn’t see any info on how to troubleshoot/trace the problem, so I would urge you to file a bug report on eAccelerator’s trac so eA’s developers can guide you in the process. Note: there’s a similar ticket open: http://www.eaccelerator.net/ticket/300

Thanks a lot for this effort. It really helped me. style_emoticons/<#EMO_DIR#>/biggrin.gif