# Redis not detected

**URL:** <https://help.nextcloud.com/t/redis-not-detected/144824>\
**Category:** ℹ️ Support\
**Tags:** redis\
**Created:** [September 1, 2022, 11:27am UTC](https://help.nextcloud.com/t/redis-not-detected/144824 "2022-09-01T11:27:33Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![katronix](https://help.nextcloud.com/user_avatar/help.nextcloud.com/katronix/32/45570_2.png) [@katronix](https://help.nextcloud.com/u/katronix)\
**Post date:** [September 1, 2022, 11:27am UTC](https://help.nextcloud.com/t/redis-not-detected/144824/1 "2022-09-01T11:27:33Z")

</div>

> **Support intro**
>
> Installed Redis on server, configured nextcloud to use it, its appears not to be able to detect it.

Nextcloud version \_ **24.0.4**  
Operating system and version Ubuntu 22.04.1 LTS  
Apache or nginx version Apache/2.4.54 (Ubuntu) nginx/1.23.1  
PHP version 8.1

The issue you are facing:

Redis is installed and working, however NextCloud doesn’t seem to see it:  
No memory cache has been configured. To enhance performance, please configure a memcache, if available. Further information can be found in the [documentation ↗](https://docs.nextcloud.com/server/24/go.php?to=admin-performance).  
Is this the first time you’ve seen this error? _(Y/N)_:Y

Steps to replicate it:

1. Install Redis Server + PHP Modules

2. Configure nextcloud using:  
‘filelocking.enabled’ =\> true,  
‘memcache.distributed’ =\> ‘\OC\Memcache\Redis’,  
‘redis’ =\>  
array (  
‘host’ =\> ‘127.0.0.1’,  
‘port’ =\> 6379,  
‘timeout’ =\> 0.0,  
),

3. 

The output of your Nextcloud log in **Admin \> Logging** :

```auto
N/A

```

The output of your config.php file in `/path/to/nextcloud` (make sure you remove any identifiable information!):

```auto
<?php
$CONFIG = array (
  'instanceid' => 'oc90bsw751tp',
  'passwordsalt' => 'YUHdvrw4qKNakI03IV8iLQq2OlFygi',
  'secret' => 'mP4RpfSGe7pemmLLvxYaFzAVlLbyECE1fwtKH4rECJdHq8tm',
  'trusted_domains' => 
  array (
    0 => '',
  ),
  'datadirectory' => '/public_html/data',
  'dbtype' => 'mysql',
  'version' => '24.0.4.1',
  'overwrite.cli.url' => '',
  'dbname' => '',
  'dbhost' => 'localhost:3306',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => '',
  'dbpassword' => '',
  'installed' => true,
  'mail_from_address' => 'nextcloud',
  'mail_smtpmode' => 'smtp',
  'mail_sendmailmode' => 'smtp',
  'mail_domain' => '',
  'mail_smtpsecure' => 'tls',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_smtpauth' => 1,
  'mail_smtphost' => '',
  'mail_smtpport' => '587',
  'mail_smtpname' => '',
  'mail_smtppassword' => '',
  'default_phone_region' => '3166-2:US',
  'updater.secret' => '',
  'filelocking.enabled' => true,
  'memcache.distributed' => '\\OC\\Memcache\\Redis',
  'redis' => 
  array (
    'host' => '127.0.0.1',
    'port' => 6379,
    'timeout' => 0.0,
  ),
  'loglevel' => 2,
  'maintenance' => false,
);

```

The output of your Apache/nginx/system log in `/var/log/ ____ `:

```auto
NA

```

NA

```auto

Output errors in nextcloud.log in /var/www/ or as admin user in top right menu, filtering for errors. Use a pastebin service if necessary.

PASTE HERE

```

---

<div class="post-metadata">

**Author:** ![eehmke](https://help.nextcloud.com/user_avatar/help.nextcloud.com/eehmke/32/8934_2.png) [@eehmke](https://help.nextcloud.com/u/eehmke)\
**Post date:** [September 1, 2022, 4:23pm UTC](https://help.nextcloud.com/t/redis-not-detected/144824/2 "2022-09-01T16:23:35Z")

</div>

Is your redis server running on a tcp port or a unix socket? Check the config in /etc/redis/redis.conf. In my redis.conf, I have a unix socket:

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

And in my nextcloud config:

> ‘redis’ =\>  
> array (  
> ‘host’ =\> ‘/var/run/redis/redis-server.sock’,  
> ‘port’ =\> 0,  
> ‘timeout’ =\> 1.5,  
> ‘password’ =\> ‘secret’,  
> ),

TCP port will also work, but you need the same settings in both files.

Btw, is your trusted\_domains array really empty? This is unrelated, but I guess that can cause problems too.

---

<div class="post-metadata">

**Author:** ![wwe](https://help.nextcloud.com/user_avatar/help.nextcloud.com/wwe/32/72963_2.png) [@wwe](https://help.nextcloud.com/u/wwe)\
**Post date:** [December 13, 2024, 2:40pm UTC](https://help.nextcloud.com/t/redis-not-detected/144824/3 "2024-12-13T14:40:19Z")

</div>


