Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
664 views
in Technique[技术] by (71.8m points)

PHP Warning: PHP Startup: Unable to load dynamic library 'redis.so'

I try to upgrade php to 8.0.1 when I finish install php and I find like that. How can I do ?

[root@localhost /]# php -v

PHP Warning: PHP Startup: Unable to load dynamic library 'redis.so' (tried: /usr/lib64/php/modules/redis.so (/usr/lib64/php/modules/redis.so: undefined symbol: _zval_ptr_dtor), /usr/lib64/php/modules/redis.so.so (/usr/lib64/php/modules/redis.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0

PHP 8.0.1 (cli) (built: Jan 5 2021 13:54:54) ( NTS gcc x86_64 ) Copyright (c) The PHP Group Zend Engine v4.0.1, Copyright (c) Zend Technologies with Xdebug v3.0.2, Copyright (c) 2002-2021, by Derick Rethans

os: Centos 7

question from:https://stackoverflow.com/questions/65902166/php-warning-php-startup-unable-to-load-dynamic-library-redis-so

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

I remove redis from centos 7.I'm not sure 100% correct but I didn't see "PHP Warning:".

[root@localhost ~]# sudo yum remove redisp

[root@localhost local]# rm -R redis

[root@localhost local]# cd /usr/lib64/php/modules

[root@localhost modules]# rm redis.so

[root@localhost modules]# cd /etc/php.d/

[root@localhost php.d]# rm redis.ini"

[root@localhost php.d]# php -v PHP 8.0.1 (cli) (built: Jan 5 2021 13:54:54) ( NTS gcc x86_64 ) Copyright (c) The PHP Group Zend Engine v4.0.1, Copyright (c) Zend Technologies with Xdebug v3.0.2, Copyright (c) 2002-2021, by Derick Rethans


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...