eZ Community » Forums » Install & configuration » PHP Fatal error: Cannot call...
expandshrink

PHP Fatal error: Cannot call overloaded function for non-object in

PHP Fatal error: Cannot call overloaded function for non-object in

Thursday 02 October 2014 6:45:44 pm - 5 replies

I did a legacy upgrade from a 2011 site to 2014 today and I'm coming up with a bizarre problem - every so often, and randomly,  I get this error:

PHP Fatal error:  Cannot call overloaded function for non-object in <site>/lib/eztemplate/classes/eztemplate.php on line 1919

If I then go to the site it displays the setup wizard as if my overrides were missing.
The error message looks like it's a symptom and not the problem because I think that function call is failing because it's not getting ini values to load autoloads...
If I run ezcache.php --clear-tag=ini - it clears up (although sometimes I have to run it twice)

I'm the only one on the machine, so it's not caused by someone doing anything on the command line or on the site.  It has run on a test and dev machine with various versions of apache/php/mysql without this coming up.

So, can anyone think of a reason why ini settings would all of a sudden disappear?

Friday 03 October 2014 3:10:53 am

What is the PHP version?

Friday 03 October 2014 9:27:57 am

php 5.3.3

Saturday 04 October 2014 5:50:47 pm

Could it be a disk issue?

Saturday 04 October 2014 9:09:50 pm

It's not space and it's not permissions... I'm pretty sure it's not inodes either.

I've been testing and a couple of things have come up that makes it even weirder -

first off I copied the files/database to a virtual machine with the same version of php/mysql - and I can't reproduce the problem.

So, I ended up restoring the old site and set up a virtual host to point to the updated directory/database - and it works fine, no problems.

Of course traffic is the one thing that's variable here - since I'm just checking with a simple wget to see if the setup page shows up and that's not really the same traffic pattern as normal use - so a lot of cache stuff is probably not being executed.

I'll set up something to try and simulate real traffic. I'm still at a loss.

Wednesday 08 October 2014 3:06:08 pm

O.k. - it  turns out it was stupid -

Someone had set up cron to kick off runcronjobs.php directly (without first cd'ing to the directory) from root and of course sending the output to /dev/null.
I suspect what happened is that something in the cronjobs replaced an ini file and it got the permissions of root - but then the next time that file was expired it couldn't overwrite it.

The function overload in eztemplate.php on line 1919 just happened to be the first thing that failed.

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from