php升级完缺少ssh2,svn扩展

xiaoxiao2021-02-28  18

在给php进行升级完毕之后,使用 php-v 出现如下错误警告: PHP Warning:  PHP Startup: imagick: Unable to initialize module Module compiled with module API=20100525 PHP    compiled with module API=20131226 These options need to match  in Unknown on line 0 PHP Warning:  PHP Startup: ssh2: Unable to initialize module Module compiled with module API=20100525 PHP    compiled with module API=20131226 These options need to match  in Unknown on line 0 PHP Warning:  PHP Startup: svn: Unable to initialize module Module compiled with module API=20100525 PHP    compiled with module API=20131226 These options need to match  in Unknown on line 0      解决方法:这是因为升级完php后,出现缺少php的扩展库

 

imagick: yum -y install php56w-pecl-imagick-devel.x86_64 php56w-pecl-imagick.x86_64

 ssh2:使用pecl库进行安装   pecl install ssh2       可参考:http://www.lnmp.cn/install-ssh2-extension-under-php-7.1.html    svn:安装svn的扩展      参考:http://www.linuxdiyf.com/linux/13948.html  wget http://pecl.php.net/get/svn-1.0.2.tgz  tar zxf svn-1.0.2.tgz   cd svn-1.0.2/  若是yum安装的php直接输入phpize,若是源码安装运行php安装的目录/usr/local/php56/bin/phpize  ./configure --with-php-config=/usr/bin/php-config  nake && make install    完后再次运行php -v 进行查看发现警告已经不存在!
转载请注明原文地址: https://www.6miu.com/read-2050093.html

最新回复(0)