- 查看MySQL状态
systemctl status mysqld
2.如果MySQL处于启动状态,则停止MySQL
systemctl stop mysqld
3.取消开机自启动
systemctl disable mysqld
4.查找已安装的MySQL包
rpm -qa | grep -i mysql
# 或
yum list installed | grep -i mysql
mysql-community-client.x86_64 8.0.33-1.el7 @mysql80-community
mysql-community-client-plugins.x86_64
8.0.33-1.el7 @mysql80-community
mysql-community-common.x86_64 8.0.33-1.el7 @mysql80-community
mysql-community-icu-data-files.x86_64
8.0.33-1.el7 @mysql80-community
mysql-community-libs.x86_64 8.0.33-1.el7 @mysql80-community
mysql-community-libs-compat.x86_64 8.0.33-1.el7 @mysql80-community
mysql-community-server.x86_64 8.0.33-1.el7 @mysql80-community
mysql80-community-release.noarch el7-7 installed
5.卸载
# 删除,一直删到查不出来为止
yum remove mysql-community-server.x86_64
yum remove mysql-community-client.x86_64
yum remove mysql80-community-release.noarch
...
6.删除MySQL相关文件
查找文件,删除找到的文件
find / -name mysql
删除my.cnf
rm /etc/my.cnf
标签:x86,CentOS,卸载,community,el7,64,mysql,MySQL,mysql80
From: https://www.cnblogs.com/lambdadog/p/18404973