PHP 7 Issue

    • 11 posts
    August 15, 2017 1:07 PM EDT

    Hey, Guys, I'm on SE 4.9, and I'm stilling getting a fatal error when I change to PHP 7. How can I fix this issue?

    • Moderator
    • 6923 posts
    August 15, 2017 3:04 PM EDT

    You would need to post the error itself. It's too hard to tell from what you say. PHP 7 works fine here on this site, on our demo and on my own site which is hosted with a different host. 

    • 11 posts
    August 15, 2017 3:20 PM EDT

     Yesterday I was getting the following message when I whiched to PHP 7.1:

    Fatal error: Uncaught Zend_Cache_Exception: The apc extension must be loaded for using this backend ! in /home/brianjgreen/public_html/talentrail.com/application/libraries/Zend/Cache.php:209 Stack trace: #0 /home/brianjgreen/public_html/talentrail.com/application/libraries/Zend/Cache/Backend/Apc.php(59): Zend_Cache::throwException('The apc extensi...') #1 /home/brianjgreen/public_html/talentrail.com/application/libraries/Zend/Cache.php(153): Zend_Cache_Backend_Apc->__construct(Array) #2 /home/brianjgreen/public_html/talentrail.com/application/libraries/Zend/Cache.php(94): Zend_Cache::_makeBackend('Apc', Array, true, false) #3 /home/brianjgreen/public_html/talentrail.com/application/libraries/Engine/Cache.php(211): Zend_Cache::factory('core', 'Apc', Array, Array, false, true, false) #4 /home/brianjgreen/public_html/talentrail.com/application/modules/Core/Bootstrap.php(283): Engine_Cache::factory('core', 'Apc', Array, Array, false, true) #5 /home/brianjgreen/public_html/talentrail.com/application/libraries/Engine/Applicatio in /home/brianjgreen/public_html/talentrail.com/application/libraries/Zend/Cache.php on line 209

    Today for some reason I'm getting a HTTP ERROR 500 now when I which to PHP 7.1 


    This post was edited by socialenginestaff at August 15, 2017 3:26 PM EDT
    • Moderator
    • 6923 posts
    August 15, 2017 3:26 PM EDT

    Looks like it is throwing an error due to the apc cache. Please change back to file based cache for now and check with your host about using APCi for cache.


    This post was edited by socialenginestaff at August 15, 2017 3:27 PM EDT
    • 11 posts
    August 15, 2017 3:36 PM EDT

    Okay, thanks. 

    • 11 posts
    August 15, 2017 3:46 PM EDT

    In the SE Admin panel, there's no caching feature for APCi. Does that matter? APC is supposed to be faster than file based caching right? I'm trying to recall if that's correct. 


    This post was edited by Brian G. at August 15, 2017 3:50 PM EDT
    • Moderator
    • 6923 posts
    August 15, 2017 3:54 PM EDT

    The APC is actually APCi now as APC was deprecated. The phrase just wasn't updated. If you want to use it, you need your host to set it up on your server first so for now, use file based. My site uses Redis cache, this site uses Redis as well. 

    • 11 posts
    August 15, 2017 4:18 PM EDT

    What's the difference performance wise with Redis cache and APCi? And I'm currently using APCu with my host, not APC. Don't see much on APCi. Is this different from APCu? 


    This post was edited by Brian G. at August 15, 2017 5:05 PM EDT
    • Moderator
    • 6923 posts
    August 16, 2017 4:53 AM EDT
    Brian G. said:

    What's the difference performance wise with Redis cache and APCi? And I'm currently using APCu with my host, not APC. Don't see much on APCi. Is this different from APCu? 

    I'm sorry, my typos above. It is APCu not APCi. 

    I don't know the performance difference but my site is fast and this one is. According to searches APCu requires more server memory to work than Redis.

    • 11 posts
    August 16, 2017 9:26 AM EDT

    Okay, cool. I saw the same thing about the server usage too. My host is suggesting Memcache right now, so I may try that out.

    • 11 posts
    August 16, 2017 10:07 AM EDT

    Memcache has been installed on my server, but the option to select it along, with Xcache and Redis are grayed out. Do these choices become selectable after they are properly installed and configured or is there something else that has to happen to select one of those cache options?

    • Moderator
    • 6923 posts
    August 16, 2017 10:31 AM EDT

    yes it would need to be properly configured, https://support.socialengine.com/php/customer/en/portal/articles/1639869-admin-panel---settings->-performance-caching?b_id=14386 and you'll need to ensure you are using SEPHP 4.9.3.

    • 11 posts
    August 16, 2017 11:56 AM EDT

    My both the memcache and memcached PHP extensions were installed, but the option to select is still grayed out for some reason. 

    • Moderator
    • 6923 posts
    August 16, 2017 12:45 PM EDT

    Are you using 4.9.3 as I mentioned? If so, there could be some other server conflict.

    • 348 posts
    August 17, 2017 3:51 AM EDT
    Brian G. said:

    What's the difference performance wise with Redis cache and APCi? And I'm currently using APCu with my host, not APC. Don't see much on APCi. Is this different from APCu? 

    Hi Brian, 

    Redis Cache works efficiently because of the low-latency, high-throughput capabilities of the Redis engine. This way the splitted cache layer allows your data tier to scale independently for more efficient use of compute resources in your application layer.

    As an added benefit, Redis offers clustering and being built-in provides a more robust solution that is easier to administrate. Redis clearly has the more compelling scaling story today. 

    We also provide Redis Cache Installation and Setup service.

    • 11 posts
    August 17, 2017 2:44 PM EDT

    My host is telling me the following about the current version SE 4.9.3; "The site is not compatible with PHP 7.0 (memcache and memcacheD DO work fine with PHP 7.0) however, the site's code is outdated and is having errors when using PHP 7.x", that's why the Memcache option was still grayed out, but I thought SE 4.9.3 was compatible with PHP 7.x? 

    • Moderator
    • 6923 posts
    August 17, 2017 5:56 PM EDT

    It works perfectly fine with PHP 7 or this site wouldn't work. The demo wouldn't work. My personal site wouldn't work and my ScriptTechs' demo site wouldn't work. All of these sites are using PHP 7.1. This site and our demo use Redis caching. All of these sites are SEPHP 4.9.3. Perhaps try cazaratech hosting or another host if your host isn't sure how to set up the hosting.

    • 11 posts
    August 18, 2017 12:25 PM EDT

    Thanks, I'm looking into cazaratech hosting now, but I'll probably get the Redis Cache Installation and Setup by SocialEngineAddOns. My current host can install Redis, but they stated configurations are up to me and Redis needs to be highly configured in order to work properly.

    • 15 posts
    August 19, 2017 1:53 AM EDT
    Brian G. said:

    My host is telling me the following about the current version SE 4.9.3; "The site is not compatible with PHP 7.0 (memcache and memcacheD DO work fine with PHP 7.0) however, the site's code is outdated and is having errors when using PHP 7.x", that's why the Memcache option was still grayed out, but I thought SE 4.9.3 was compatible with PHP 7.x? 

    Dear Brian, many of the difficulties I have experienced with SE v4.9.2p1 have resolved once I upgraded PHP 7.0.x to 7.1.8

    Hope it'll help you too.

    • 629 posts
    September 9, 2017 3:36 AM EDT

    Brian G., welcome to the community!

    I two am having issues with the options for memcache and apcu being graded out. I use a very popular shared hosting standard with Cloud Linux and Name Cheap. One thing you could try, see if your server host is blocking the ports for the extensions to connect through to social engine. This may fix the issue. I use php7.1 fine. Redhis is not available for me.

    • 11 posts
    September 11, 2017 10:46 AM EDT

    Thanks, Elshara, I will follow up with my hosting provider to see if that's the case. Right now I have things working, but not exactly how I want it to function with SE.