当前位置:网站首页>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已完美卸载
边栏推荐
- 【CV项目调试】CUDNN_CONVOLUTION_FWD_SPECIFY_WORKSPACE_LIMIT问题
- Teach you how to configure Jenkins automated email notifications
- [1154]如何将字符串转换为datetime
- Intel's software and hardware optimization empowers Neusoft to accelerate the arrival of the era of smart medical care
- Verify the integer input
- 怎样做好一个创业公司CTO?
- mysql view
- The application of AI in the whole process of medical imaging equipment
- How to do a startup CTO?
- 【银行系列第一期】中国人民银行
猜你喜欢
19. Support Vector Machines - Intuitive Understanding of Optimization Objectives and Large Spacing
CMOS和TTL的区别?
Tower of Hanoi problem
After reading "MySQL Database Advanced Practice" (SQL Xiao Xuzhu)
Force buckled brush the stairs (7/30)
Shell script to loop through values in log file to sum and calculate average, max and min
曼城推出可检测情绪的智能围巾,把球迷给整迷惑了
Introduction to flask series 】 【 flask - using SQLAlchemy
The final exam first year course
汉源高科8路HDMI综合多业务高清视频光端机8路HDMI视频+8路双向音频+8路485数据+8路E1+32路电话+4路千兆物理隔离网络
随机推荐
leetcode-952: Calculate max component size by common factor
LeetCode 每日一题 2022/7/25-2022/7/31
Tower of Hanoi problem
Layer 2 broadcast storm (cause + judgment + solution)
Force buckled brush the stairs (7/30)
Project development software directory structure specification
cudaMemcpy学习笔记
The effective square of the test (one question of the day 7/29)
Arbitrum Interview | L2 Summer, what does the standout Arbitrum bring to developers?
The Sad History of Image Processing Technology
C language applet -- common classic practice questions
The difference between link and @import
f.grid_sample
MPPT solar charge controller data collection - through the gateway acquisition capacity battery SOC battery voltage, wi-fi
221. Largest Square
Basic learning about Redis related content
Drools WorkBench的简介与使用
Difference between CMOS and TTL?
uniapp uses 3rd party fonts
Real-time image acquisition based on FPGA