Home  >  Article  >  Database  >  Introduction to the method of uninstalling Mysql5.7.19 under Linux

Introduction to the method of uninstalling Mysql5.7.19 under Linux

黄舟
黄舟Original
2017-09-02 13:31:061642browse

Before uninstalling mysql, you need to check whether mysql has been installed before. The specific search commands are introduced in this article. This article focuses on introducing the uninstallation method of Mysql5.7.19 under Linux. Friends who need it can refer to it

1. Find whether mysql has been installed before

Command:rpm -qa|grep -i mysql

You can see the two packages of mysql:


mysql-*..*.RHEL**
mysqlclient*.RHEL**

2. Delete mysql

Delete command: rpm -e --nodeps Package name

( rpm - ev mysql-*.RHEL* )

3. Delete the development header files and libraries of the old version of mysql

Command:


rm -fr /usr/lib/mysql
rm -fr /usr/include/mysql

Note: The data in /var/lib/mysql and /etc/my.cnf will not be deleted after uninstallation. If it is determined to be useless, delete it manually


rm -f /etc/my.cnf
  rm -fr /var/lib/mysql

Summary

The above is the detailed content of Introduction to the method of uninstalling Mysql5.7.19 under Linux. 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