0

I have a project based on drupal 6. I installed php5.6 and redis and php-redis on ubuntu. Now, when I run my project, faced 'Class 'Predis\Client' not found in'.

also my redis config in setting file is like this:

$conf['redis_client_interface']           = 'Predis';
$conf['cache_backends'][]                 = 'sites/all/modules/redis/redis.autoload.inc';
$conf['cache_class_cache']                = 'Redis_Cache';
$conf['cache_class_cache_menu']           = 'Redis_Cache';
$conf['cache_class_cache_drupal_get_filename'] = 'Redis_Cache';
$conf['cache_class_cache_bootstrap']      = 'Redis_Cache';
$conf['cache_class_cache_path']           = 'Redis_Cache';
$conf['cache_class_cache_field']          = 'Redis_Cache';
$conf['cache_class_cache_views']          = 'Redis_Cache';
$conf['cache_class_cache_admin_menu']     = 'Redis_Cache';
$conf['lock_inc']                         = 'sites/all/modules/redis/redis.lock.inc';
7
  • Does php-redis match installed php version? Did you enable the extension in php.ini Commented Aug 26, 2022 at 6:59
  • I install php-redis with sudo apt install php5.6-redis. I dont know how to enable the extension in php.ini. Commented Aug 26, 2022 at 7:05
  • You can check if its enabled by running php -m to enable it you would need to add extension=redis.so to your php.ini Commented Aug 26, 2022 at 7:10
  • when run php -m | grep redis, there is only redis. is ti enough? Commented Aug 26, 2022 at 7:17
  • composer require predis/predis Commented Aug 26, 2022 at 7:20

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.