Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
When enabling authcache and memcache, I get this error:
Call to undefined function lock_acquire() in /var/www/forum/includes/bootstrap.inc on line 935
One way to resolve it is to modify this code in authcache.inc line 66 - line 71
// Connect to database if default database cache hander is selected (or memcached which currently requires database access to run variable_initialize)
if ($conf['authcache_is_db'] || $memcache == 'MemCacheDrupal') {
require_once DRUPAL_ROOT . '/includes/database/database.inc';
require_once DRUPAL_ROOT . '/includes/lock.inc';
db_set_active();
}
But I know memcache has a memcache based locking included in memcache-lock.inc, I tried loading that file but it gives me fatal error for re-declaring lock_aquire().
My settings for memcache and authcache are :
$conf['cache_backends'][] = 'sites/all/modules/contrib/memcache/memcache.inc';
$conf['cache_backends'][] = 'sites/all/modules/contrib/authcache/authcache.inc';
$conf['cache_default_class'] = 'MemCacheDrupal';
$conf['cache_class_cache_page'] = 'MemCacheDrupal';
Comments
Comment #0.0
awm CreditAttribution: awm commentededit format and spellings
Comment #1
ruedu CreditAttribution: ruedu commentedI'm seeing the same issue. I'm noticing however that it only happens if the caches are already empty, at least under my current configuration.
Comment #2
ruedu CreditAttribution: ruedu commenteddouble post...
Comment #3
znerol CreditAttribution: znerol commentedResolved as of 7.x-1.1 (see #966152-85: Authcache » Drupal 7 port)
Comment #3.0
znerol CreditAttribution: znerol commentedformat