https://pecl.php.net/package/redis选择自己的版本
wget https://pecl.php.net/get/redis-4.2.0.tgz
tar -zxvf redis-4.2.0.tgz
cd redis-4.2.0
/usr/local/php73/bin/phpize
./configure --with-php-config=/usr/local/php73/bin/php-config
make&&make install
修改php.ini配置,添加
extension=redis.so
重启php-fpm即可