1

I'm testing out moving my Roundcube 1.3.8 install over to php 7.3. It's load balanced and I have been using memcache for session storage with php 5 without any issues: $config['session_storage'] = 'memcache';

// Use these hosts for accessing memcached
// Define any number of hosts in the form of hostname:port or unix:///path/to/socket.file
$config['memcache_hosts'] = array( 'server1:11211','server2:11211');

When I try out this same config on php 7.3.3 I get the following error:

[17-Mar-2019 19:11:16 +0000]: DB Error: Failed to connect to memcached. Please check configuration in /path/to/roundcube/program/lib/Roundcube/rcube_session_memcache.php on line 49 (GET /mail/)

I've been able to run a simple test script from php 7.3 to verify that memcache is indeed working.

Any suggestions why this won't work with Roundcube 1.3.8?

1 Answer 1

1

TL;DR: Switch to redis.

PHP 7 no longer supports php-memcache, and the project appears abandoned. Only php-memcached is supported. These are two different PHP APIs for using memcached. Roundcube hasn't been updated to use the new API, and apparently never will. A few distros are maintaining a fork of the old API but yours probably isn't one of them, and you should expect even that to go away eventually.

5
  • Yeah - I was aware of the two different apis. It was unclear that roundcube doesn't support php-memcached and only supports php-memcache. Is there any roundcube support for redis - or would it just be relying on php session handling to save to redis?
    – Aaron A
    Mar 18, 2019 at 1:06
  • Well, that's all roundcube does anyway, is to use PHP's existing session save handlers. But they all require slightly different setup, so the PHP app has to support each of them. Roundcube does support redis. Mar 18, 2019 at 1:18
  • Following the thread above, it seems that there is already a version on the forge that will (experimentally) use php-memcached. It's just a question of time until it becomes available on all sorts of distros... Jun 4, 2019 at 15:43
  • 1
    @GwynethLlewelyn The problem isn't that php-memcached isn't available (it is in virtually every distro that has PHP, and is currently maintained) - the problem is that roundcube did not support it. Jun 4, 2019 at 15:45
  • @MichaelHampton I stand corrected! Jun 27, 2019 at 22:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .