XF 1.5 An unexpected error occurred. "The memcache extension must be loaded for using this backend"

jb9826

Member
I transferred my forum to a new server. I moved the files and database. When i load the domain it shows a white page with:

"An unexpected error occurred. Please try again later."

XenForo 1.5.24
php version: 5.6 php-fpm

unexpected-error.jpg

So i installed a fresh version of xenforo and it works fine

XenForo 1.5.24
php version: 5.6 php-fpm

test.jpg



I looked in the admin panel of the forum that doesn't work and i see this:


Code:
Error Info
Zend_Cache_Exception: The memcache extension must be loaded for using this backend ! - library/Zend/Cache.php:209
Generated By: Unknown Account, A moment ago
Stack Trace
#0 /home/myforum/domains/example.com/public_html/library/Zend/Cache/Backend/Memcached.php(123): Zend_Cache::throwException('The memcache ex...')
#1 /home/myforum/domains/example.com/public_html/library/Zend/Cache.php(153): Zend_Cache_Backend_Memcached->__construct(Array)
#2 /home/myforum/domains/example.com/public_html/library/Zend/Cache.php(94): Zend_Cache::_makeBackend('Memcached', Array, false, false)
#3 /home/myforum/domains/example.com/public_html/library/XenForo/Application.php(766): Zend_Cache::factory('Core', 'Memcached', Array, Array)
#4 /home/myforum/domains/example.com/public_html/library/XenForo/Application.php(976): XenForo_Application->loadCache(Object(Zend_Config))
#5 /home/myforum/domains/example.com/public_html/library/XenForo/Application.php(1007): XenForo_Application->lazyLoad('cache', NULL)
#6 /home/myforum/domains/example.com/public_html/library/XenForo/Application.php(1678): XenForo_Application::get('cache')
#7 /home/myforum/domains/example.com/public_html/library/XenForo/Model.php(146): XenForo_Application::getCache()
#8 /home/myforum/domains/example.com/public_html/library/XenForo/Model/DataRegistry.php(81): XenForo_Model->_getCache(true)
#9 /home/myforum/domains/example.com/public_html/library/XenForo/Dependencies/Abstract.php(147): XenForo_Model_DataRegistry->getMulti(Array)
#10 /home/myforum/domains/example.com/public_html/library/XenForo/FrontController.php(127): XenForo_Dependencies_Abstract->preLoadData()
#11 /home/myforum/domains/example.com/public_html/index.php(13): XenForo_FrontController->run()
#12 {main}
Request State
array(3) {
  ["url"] => string(22) "[URL]https://example.com/[/URL]"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(0) {
  }
}





I tried different php versions

My Forum - XenForo 1.5.24
PHP 5.6 php-fpm - doesn't work
PHP 7.0 php-fpm - doesn't work
PHP 7.1 php-fpm - doesn't work
PHP 7.2 php-fpm - WORKS


Test Forum(fresh install) - XenForo 1.5.24
PHP 5.6 php-fpm - WORKS
PHP 7.0 php-fpm - WORKS
PHP 7.1 php-fpm - WORKS
PHP 7.2 php-fpm - WORKS


Is someone able to tell me why my forum doesn't work with any of the other php versions except 7.2 but the fresh install works on every php version? I've disabled all add-ons and same problem.
 
It seems there was a cache set. I looked in config.php and there was this:

Code:
$config['cache'] = array(
    'enabled'                      => true,
    'cacheSessions'                => true,
    'frontend'                     => 'Core',
    'frontendOptions'              => array(
        'caching'                  => true,
        'cache_id_prefix'          => 'myforum_',
        'automatic_serialization'  => false,
        'lifetime'                 => 0),
    'backend'                      => 'Memcached',
    'backendOptions'               => array(
        'servers'                  => array(
            array(
                'host'             => 'localhost',
                'port'             => 11211,
                'weight'           => 1
            )
        )
    )
);


I deleted it all that info above and now it works with php version 5.6 and all others!
I don't remember adding that in there but i haven't really touched anything in the config file for years.
The reason i wanted to keep the php version low is because an add-on doesnt work with higher php versions

everything is working now. thanks
 
Top Bottom