当前位置:网站首页>CentOS7下mysql5.7.37的卸载【完美方案】
CentOS7下mysql5.7.37的卸载【完美方案】
2022-07-31 02:30:00 【倾心*】
执行如下命令查看已经安装的mysql
[[email protected] ~]# rpm -qa|grep -i mysql
mysql-community-client-5.7.37-1.el7.x86_64
mysql-community-common-5.7.37-1.el7.x86_64
mysql-community-server-5.7.37-1.el7.x86_64
mysql-community-libs-5.7.37-1.el7.x86_64
mysql-community-libs-compat-5.7.37-1.el7.x86_64
使用yum -y remove命令删除
#方式一 一次性全部删除
yum -y remove mysql*
#方式二 逐个逐个删除
yum -y remove mysql-community-client-5.7.37-1.el7.x86_64
yum -y remove mysql-community-common-5.7.37-1.el7.x86_64
yum -y remove mysql-community-server-5.7.37-1.el7.x86_64
yum -y remove mysql-community-libs-5.7.37-1.el7.x86_64
yum -y remove mysql-community-libs-compat-5.7.37-1.el7.x86_64
保险起见一个一个删除 可能在删除某个安装包时 其他安装包也会跟着删除 为了卸载干净 这样操作也未尝不可
卸载以上安装包之后 查看有关mysql的目录 全部删除
[[email protected] ~]# find / -name mysql
/etc/logrotate.d/mysql
/var/lib/mysql
/var/lib/mysql/mysql
/usr/bin/mysql
/usr/lib64/mysql
/usr/share/mysql
/usr/local/software/mysql
使用 rm -rf 命令将上面的目录依次删除 直至查询不到上述目录
[[email protected] ~]rm -rf /etc/logrotate.d/mysql
[[email protected] ~]rm -rf /var/lib/mysql
[[email protected] ~]rm -rf /var/lib/mysql/mysql
[[email protected] ~]rm -rf /usr/bin/mysql
[[email protected] ~]rm -rf /usr/lib64/mysql
[[email protected] ~]rm -rf /usr/share/mysql
[[email protected] ~]rm -rf /usr/local/software/mysql
删除mysql配置文件
[[email protected] ~]# rm -rf /etc/my.cnf
删除mysql默认密码
rm -rf /root/.mysql_history
rm -rf /root/mysql_secret
至此mysql5.7.37已完美卸载
边栏推荐
- To write good test cases, you must first learn test design
- Intel's software and hardware optimization empowers Neusoft to accelerate the arrival of the era of smart medical care
- leetcode-952: Calculate max component size by common factor
- How to design the changing system requirements
- 真正的CTO,是一个懂产品的技术人
- 跨专业考研难度大?“上岸”成功率低?这份实用攻略请收下!
- ShardingJDBC使用总结
- 12 pictures take you to fully understand service current limit, circuit breaker, downgrade, and avalanche
- Basic learning about Redis related content
- Maximum monthly salary of 20K?The average salary is nearly 10,000... What is the experience of working in a Huawei subsidiary?
猜你喜欢
12 pictures take you to fully understand service current limit, circuit breaker, downgrade, and avalanche
Layer 2 broadcast storm (cause + judgment + solution)
Nacos
你们程序员为什么不靠自己的项目谋生?而必须为其他人打工?
ShardingJDBC基本介绍
The comprehensive result of the case statement, do you know it?[Verilog Advanced Tutorial]
公司官网建站笔记(六):域名进行公安备案并将备案号显示在网页底部
Software testing basic interface testing - getting started with Jmeter, you should pay attention to these things
General introduction to the Unity interface
Live Preview | KDD2022 Doctoral Dissertation Award Champion and Runner-up Dialogue
随机推荐
知识蒸馏7:知识蒸馏代码详解
系统需求多变如何设计
拒绝加班,程序员开发的效率工具集
[1153]mysql中between的边界范围
【AcWing 62nd Weekly Game】
全流程调度——MySQL与Sqoop
怎样做好一个创业公司CTO?
Layer 2 broadcast storm (cause + judgment + solution)
Nacos
1. Non-type template parameters 2. Specialization of templates 3. Explanation of inheritance
Drools规则属性,高级语法
My first understanding of MySql, and the basic syntax of DDL and DML and DQL in sql statements
Installation, start and stop of redis7 under Linux
直播预告 | KDD2022博士论文奖冠亚军对话
Intel's software and hardware optimization empowers Neusoft to accelerate the arrival of the era of smart medical care
基于FPGA的售货机
经典链表OJ强训题——快慢双指针高效解法
你们程序员为什么不靠自己的项目谋生?而必须为其他人打工?
Can an inexperienced college graduate switch to software testing?my real case
【CV项目调试】CUDNN_CONVOLUTION_FWD_SPECIFY_WORKSPACE_LIMIT问题