欢迎访问 生活随笔!

生活随笔

当前位置: 首页 >

centos中卸载php,在Centos 7上完成PHP的卸载和重新安装

发布时间:2025/4/5 60 豆豆
生活随笔 收集整理的这篇文章主要介绍了 centos中卸载php,在Centos 7上完成PHP的卸载和重新安装 小编觉得挺不错的,现在分享给大家,帮大家做个参考.

基本上,我编辑了remi repo配置文件以启用PHP 5.6和5.5,并安装了php5.6。我测试了我想要测试的内容,并试图通过禁用repos并卸载所有php然后重新安装来切换回原来的状态。现在我有问题了。

以下是症状和我所做的尝试。

我收到一条关于WordPress安装的消息”

Your PHP installation appears to be missing the MySQL extension which is required by WordPress.

"

# php -v

PHP **7.2.14** (cli) (built: Jan 8 2019 14:05:15) ( NTS )

Copyright (c) 1997-2018 The PHP Group

phpinfo() ?> works but says php version **7.1.24**

# yum list installed | grep php

php.x86_64 7.2.14-1.el7.remi @remi-php72

php-cli.x86_64 7.2.14-1.el7.remi @remi-php72

php-common.x86_64 7.2.14-1.el7.remi @remi-php72

php-gd.x86_64 7.2.14-1.el7.remi @remi-php72

php-json.x86_64 7.2.14-1.el7.remi @remi-php72

php-mysqlnd.x86_64 7.2.14-1.el7.remi @remi-php72

php-pdo.x86_64 7.2.14-1.el7.remi @remi-php72

php-pecl-mcrypt.x86_64 1.0.1-6.el7.remi.7.2 @remi-php72

# yum install php-mysql

Loaded plugins: fastestmirror, langpacks

Loading mirror speeds from cached hostfile

* base: mirror.layeronline.com

* epel: mirror.uic.edu

* extras: centos.mirror.globo.tech

* nux-dextop: mirror.li.nux.ro

* remi: repo1.ash.innoscale.net

* remi-php72: repo1.ash.innoscale.net

* remi-safe: repo1.ash.innoscale.net

* updates: centos.mirror.ca.planethoster.net

* webtatic: us-east.repo.webtatic.com

Package php-mysql-5.4.45-16.el7.remi.x86_64 is obsoleted by php-mysqlnd-7.2.14-1.el7.remi.x86_64 which is already installed

有没有什么简单的解决方法,或者我应该重新安装整个开发机器。

总结

以上是生活随笔为你收集整理的centos中卸载php,在Centos 7上完成PHP的卸载和重新安装的全部内容,希望文章能够帮你解决所遇到的问题。

如果觉得生活随笔网站内容还不错,欢迎将生活随笔推荐给好友。