Concrete5.7 Symphony error

Permalink
We received this error recently on our website. We are running version Concrete 5.7.5.9.


An unexpected error occurred.

Class Symfony\Component\HttpFoundation\Session\Storage\Proxy\SessionHandlerProxy contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (SessionHandlerinterface:read)

InformaticsInc
 
MrKDilkington replied on at Permalink Reply
MrKDilkington
Hi InformaticsInc,

I also get this error randomly. It started after switching to PHP 7. It requires restarting my server.

Might be related to opcache maybe?
https://github.com/symfony/symfony/issues/21213...
http://stackoverflow.com/questions/36088683/php-7-symfony-3-fatal-e...
InformaticsInc replied on at Permalink Reply
InformaticsInc
Thanks for your response,
We did do a restart which did resolve the issue. Is Concrete5 working on a fix for this issue or have they resolved this in version 8?
Do you have any suggestions for tracking this issue so that I can resolve this immediately when this occurs?
MrKDilkington replied on at Permalink Reply
MrKDilkington
@InformaticsInc

I am not sure if I have encountered this in v8.

Since it happens so randomly, I am not sure what the best approach to handle it is.
InformaticsInc replied on at Permalink Reply
InformaticsInc
Thanks,

Do you have any advice on who we should reach out to for this error, such as Symfony? Also, do you know what http status code this error generates?
MrKDilkington replied on at Permalink Reply
MrKDilkington
@InformaticsInc

I spoke to a core team member about this, here is their response:
"You should always clear opcache whenever changing code. You can do that by reloading phpfpm or nginx or apache or whatever you’re using. If you’re not changing code underneath it, perhaps you have two different versions of the same file sharing the same cache pool / fpm pool - in that case I’d say 'Don’t do that'"
InformaticsInc replied on at Permalink Reply
InformaticsInc
At the time we were not doing any code changes. The only difference between this site and the many other Concrete5 sites that we host and/or developed is that this is the first site that is running on PHP7.1.
Could you explain a little further about the file sharing in the same cache pool? we are using Apache 2.4 with no fpm.
We really need to fix this issue so that our client does not experience any more downtime. Any suggestions you have to correct this issue would be appreciated.
MrKDilkington replied on at Permalink Reply
MrKDilkington
@InformaticsInc

I am afraid I don't know much about the cause or how it might be resolved.

A side note, I had this happen on v8 last night.

Have you checked the bug tracker to see if others are experiencing this issue? If no one has reported this issue, I recommend reporting it and including the specific steps required to repeat the error.

concrete5 bug tracker
https://www.concrete5.org/developers/bugs...
InformaticsInc replied on at Permalink Reply
InformaticsInc
Here is more detailed information that I found in the error log:

PHP Fatal error: Uncaught Error: Cannot instantiate abstract class Symfony\Component\HttpFoundation\Session\Storage\Proxy\SessionHandlerProxy in example.com\concrete\vendor\symfony\http-foundation\Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage.php:364


Stack trace:
#0 example.com\concrete\vendor\symfony\http-foundation\Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage.php(112): Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage->setSaveHandler(Object(Concrete\Core\Session\Storage\Handler\NativeFileSessionHandler))

#1 example.com\concrete\src\Session\SessionFactory.php(68): Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage->__construct(Array, Object(Concrete\Core\Session\Storage\Handler\NativeFileSessionHandler))

#2 example.com\concrete\src\Session\Se in example.com\concrete\vendor\symfony\http-foundation\Symfony\Component\HttpFoundation\Session\Storage\NativeSessionStorage.php on line 364
InformaticsInc replied on at Permalink Reply
InformaticsInc
If this issue is where opcache is causing a problem with sessions being stored on the file system, could switching the sessions to be stored in the database resolve this issue?
Gondwana replied on at Permalink Reply
Gondwana
I just encountered this issue immediately after running the 'rebuild search index'(?) automated job. c5 8.2.1. Interestingly, it brought down ALL installations of c5 that were installed on my machine, and not just the one in which I ran the job.

Restarting apache made it go away.