Hello,
I am also trying to setup mautic to use Redis so I figured I would use an old post since there is no solution reply.
Your software
My Mautic version is: 4.1.1
My PHP version is: 7.4
My Database type and version is: MariaDB 10.3
Your problem
My problem is:
I am trying to configure Mautic so that it uses Redis instead of filesystem cache. I installed redis-server package on my system as well as php-redis.
These errors are showing in the log:
[no errors detect in logs]
Steps I have tried to fix the problem:
I have tried to looking into documentation here: https://developer.mautic.org/?php&_ga=2.63514735.1361225527.1642110543-284173810.1641816063#configuration and I tried to reverse engineer whats happening (I looked into cache bundle). I also consult Symfony docs to see how to configure a dsn.
I came up with the following configuration I put into app/config/local.php:
'cache_adapter' => 'mautic.cache.adapter.redis',
'cache_adapter_redis' => array(
'dsn' => 'redis://<ip>:<port>/<database-index>',
'options' => array(
'lazy' => false,
'persistent' => 0,
'persistent_id' => null,
'timeout' => 30,
'read_timeout' => 0,
'retry_interval' => 0,
),
),
'cache_prefix' => 'pa_',
'cache_lifetime' => 3600
But it does not seem to have any effect. When I am using Mautic and regulary inspecting the contents of redis database there is no entries, meanwhile I can see that cache is being generated on the filesystem. What am I doing wrong?
Any help would be much appreciated.
Regards, M.