当前位置:网站首页>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已完美卸载
边栏推荐
- General introduction to the Unity interface
- Unity界面总体介绍
- AtCoder Beginner Contest 261 Partial Solution
- How to design the changing system requirements
- mysql index
- My first understanding of MySql, and the basic syntax of DDL and DML and DQL in sql statements
- How to expose Prometheus metrics in go programs
- 验证整数输入
- LeetCode 每日一题 2022/7/25-2022/7/31
- Coldfusion file read holes (CVE - 2010-2861)
猜你喜欢
ShardingJDBC基本介绍
ShardingJDBC使用总结
mmdetection训练一个模型相关命令
General introduction to the Unity interface
Fiddler captures packets to simulate weak network environment testing
英特尔软硬优化,赋能东软加速智慧医疗时代到来
图解lower_bound&upper_bound
STM32CUBEMX develops GD32F303 (11) ---- ADC scans multiple channels in DMA mode
Hanyuan Hi-Tech 8-channel HDMI integrated multi-service high-definition video optical transceiver 8-channel HDMI video + 8-channel two-way audio + 8-channel 485 data + 8-channel E1 + 32-channel teleph
跨专业考研难度大?“上岸”成功率低?这份实用攻略请收下!
随机推荐
完整复制虚拟机原理(云计算)
BAT can't sell "Medical Cloud": Hospitals flee, mountains stand, and there are rules
ShardingJDBC usage summary
16. Registration Center-consul
Path and the largest
cudaMemcpy study notes
What are the project management tools like MS Project
Difference between CMOS and TTL?
12 磁盘相关命令
拒绝加班,程序员开发的效率工具集
曼城推出可检测情绪的智能围巾,把球迷给整迷惑了
Maximum area of solar panel od js
Software Testing Defect Reporting - Definition, Composition, Defect Lifecycle, Defect Tracking Post-Production Process, Defect Tracking Process, Purpose of Defect Tracking, Defect Management Tools
leetcode-128: longest continuous sequence
934. The Shortest Bridge
Android's webview cache related knowledge collection
The modification is not properly placed in the sandbox, causing Apple compatibility issues
修改未正确放入沙盒造成苹果兼容性问题
Basic learning about Redis related content
10 权限介绍