Home >Backend Development >PHP Problem >How to uninstall php installed from source code

How to uninstall php installed from source code

藏色散人
藏色散人Original
2020-08-28 09:22:205437browse

How to uninstall PHP installed from the source code: first check the PHP version through the "php -v" command; then execute the command "yum remove php" to delete PHP; finally check the remaining PHP version through the "rpm -qa | grep php" command Download the php package and delete it.

How to uninstall php installed from source code

Recommended: "PHP Video Tutorial"

Uninstall PHP from the source code under Linux

Uninstall the original There is PHP

Check the PHP version

php -v

The following command to delete php is not clean, but delete it first

yum remove php

Check the remaining php packages, which will have dependencies, so they must be Delete them sequentially

rpm -qa | grep php

pdo is a dependency of mysql; common is a dependency of gd; so delete mysql first, gd

rpm -e php-mysql

As you can see from this picture, you will be reminded when it cannot be deleted. dependent package, so you have to delete that package first until it no longer appears after running php -v

The above is the detailed content of How to uninstall php installed from source code. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn