Redis works but Nextcloud does not see it

Raspberry Pi Debian GNU/Linux 11 (bullseye)
Nextcloud 27.0.0
Apache/2.4.56 (Debian)
PHP Version 8.1.20

Using the web interface I upgraded from 26.0.3 to 27.0.0 and now I have the message:

The database is used for transactional file locking. To enhance performance, please configure memcache, if available. See the documentation :arrow_upper_right: for more information.

I found that I had to install Redis which I did not need before:

sudo apt update
sudo apt upgrade
sudo apt install redis-server php-redis

I changed the next lines in /etc/redis/redis.conf to prepare for socket mode:

requirepass secret
unixsocket /var/run/redis/redis-server.sock
port 0
unixsocketperm 760

Testing redis:

First using user pi to receive an error which is just fine because pi has no rights to /run/redis/redis-server.sock
redis-cli -a secret -s /run/redis/redis-server.sock ping
Warning: Using a password with ‘-a’ or ‘-u’ option on the command line interface may not be safe.
Could not connect to Redis at /run/redis/redis-server.sock: Permission denied

From the root account after sudo -i

redis-cli -a secret -s /run/redis/redis-server.sock ping
Warning: Using a password with ‘-a’ or ‘-u’ option on the command line interface may not be safe.
PONG

use www-data to ping
sudo -u www-data redis-cli -a secret -s /run/redis/redis-server.sock ping
Warning: Using a password with ‘-a’ or ‘-u’ option on the command line interface may not be safe.
PONG

use www-data to create a value for test
sudo -u www-data redis-cli -a secret -s /run/redis/redis-server.sock set test something
Warning: Using a password with ‘-a’ or ‘-u’ option on the command line interface may not be safe.
OK

redis-cli -a secret -s /run/redis/redis-server.sock get test
Warning: Using a password with ‘-a’ or ‘-u’ option on the command line interface may not be safe.
“something”

So far so good, this works but I can not get Nextcloud working with Redis.

End of /var/www/nextcloud/config/config.php

‘filelocking.enabled’ => true,
‘memcache.local’ => ‘\OC\Memcache\APCu’,
‘memcache.locking’ => ‘\OC\Memcache\Redis’,
‘redis’ =>
array (
‘host’ => ‘/var/run/redis/redis-server.sock’,
‘port’ => 0,
‘timeout’ => 0.0,
‘password’ => ‘secret’,
),
);

Restarting redis and apache does not help. Even rebooting does not help. The message stays and the command line commands are oke after reboot.

I checked the logging in the web GUI but there are no messages after the upgrade from 26.0.3 to 27.0.0

I must be missing something but I can not find it.

Which method do you follow to install Nextcloud on your Raspberry Pi?

I keep all my installation notes on Nextcloud and changes I make afterwards in my github GitHub - JackV2020/Nextcloud-Raspberry-Apache-Mariadb: My notes to get to 27.0.0 and to get a green checkmark and pass all security checks My last clean installation was 25.0.4 and is documented there. There are also some small documents on what I encountered during later upgrades.
I hope to add one for redis…

Fixed it using info from Redis Unix Socket
I did it for php8.1:
sudo apt install php8.1-redis
sudo phpenmod redis
sudo systemctl restart apache2
And the message is not there anymore :slight_smile: