五、Centos7安装mysql:第一步查看系统有无mysql,然后删除之
CentOS下MySQL的彻底卸载
2015年10月12日 00:16:02
- 标签:
</ul>
<ul class="right_bar">
<li><button class="btn-noborder"><i class="icon iconfont icon-read"></i><span class="txt">21149</span></button></li>
<!--<li><button class="btn-noborder"><i class="icon iconfont icon-dashang-"></i><span class="txt">0</span></button></li>-->
<li class="edit" style="display: none;">
<a class="btn-noborder" href="http://write.blog.csdn.net/postedit/49057073">
<i class="icon iconfont icon-bianji"></i><span class="txt">编辑</span>
</a>
</li>
<li class="del" style="display: none;">
<a class="btn-noborder" onclick="javascript:deleteArticle(fileName);return false;">
<i class="icon iconfont icon-shanchu"></i><span class="txt">删除</span>
</a>
</li>
</ul>
</div>
<div id="article_content" class="article_content csdn-tracking-statistics" data-mod="popu_307" data-dsm="post">
#################CentOS7下MySQL的卸载####################
1:查看MySQL是否安装:
方式1:
- [root@localhost usr]# yum list installed mysql*
- Loaded plugins: fastestmirror
- Loading mirror speeds from cached hostfile
- * base: mirrors.yun-idc.com
- * extras: mirror.neu.edu.cn
- * updates: mirrors.yun-idc.com
- Installed Packages
- MySQL-client.x86_64 5.6.27-1.el6 installed
- MySQL-devel.x86_64 5.6.27-1.el6 installed
- MySQL-server.x86_64 5.6.27-1.el6 installed
- [root@localhost usr]#

[root@localhost usr]# yum list installed mysql*
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.yun-idc.com
* extras: mirror.neu.edu.cn
* updates: mirrors.yun-idc.com
Installed Packages
MySQL-client.x86_64 5.6.27-1.el6 installed
MySQL-devel.x86_64 5.6.27-1.el6 installed
MySQL-server.x86_64 5.6.27-1.el6 installed
[root@localhost usr]#
方式2( -i :不区分大小写):
- [root@localhost usr]# rpm -qa | grep -i mysql
- MySQL-server-5.6.27-1.el6.x86_64
- MySQL-client-5.6.27-1.el6.x86_64
- MySQL-devel-5.6.27-1.el6.x86_64
- [root@localhost usr]#

[root@localhost usr]# rpm -qa | grep -i mysql
MySQL-server-5.6.27-1.el6.x86_64
MySQL-client-5.6.27-1.el6.x86_64
MySQL-devel-5.6.27-1.el6.x86_64
[root@localhost usr]#
2:卸载MySQL:
卸载1:
- [root@localhost usr]# yum remove mysql mysql-server mysql-libs compat-mysql51
- [root@localhost usr]# rm -rf /var/lib/mysql
- [root@localhost usr]# rm /etc/my.cnf

[root@localhost usr]# yum remove mysql mysql-server mysql-libs compat-mysql51
[root@localhost usr]# rm -rf /var/lib/mysql
[root@localhost usr]# rm /etc/my.cnf
如果装了mysql-devel(其他一样add command),卸载为:
- [root@Tony_ts_tian init.d]# yum remove mysql mysql-devel mysql-server mysql-libs compat-mysql51

[root@Tony_ts_tian init.d]# yum remove mysql mysql-devel mysql-server mysql-libs compat-mysql51
注(例如):
mysql-libs-5.5.39-1.el6.remi.x86_64
mysql-server-5.5.39-1.el6.remi.x86_64
- [root@localhost mysql]# rpm -aq | grep -i mysql
- MySQL-server-5.6.27-1.el6.x86_64
- MySQL-client-5.6.27-1.el6.x86_64
- MySQL-devel-5.6.27-1.el6.x86_64
- [root@localhost mysql]# rpm -e MySQL-server-5.6.27-1.el6.x86_64
- [root@localhost mysql]# rpm -e MySQL-client-5.6.27-1.el6.x86_64
- [root@localhost mysql]# rpm -e MySQL-devel-5.6.27-1.el6.x86_64
- [root@localhost rc.d]# cd /var/lib/
- [root@localhost lib]# rm -rf mysql/

[root@localhost mysql]# rpm -aq | grep -i mysql
MySQL-server-5.6.27-1.el6.x86_64
MySQL-client-5.6.27-1.el6.x86_64
MySQL-devel-5.6.27-1.el6.x86_64
[root@localhost mysql]# rpm -e MySQL-server-5.6.27-1.el6.x86_64
[root@localhost mysql]# rpm -e MySQL-client-5.6.27-1.el6.x86_64
[root@localhost mysql]# rpm -e MySQL-devel-5.6.27-1.el6.x86_64
[root@localhost rc.d]# cd /var/lib/
[root@localhost lib]# rm -rf mysql/
- [root@localhost usr]# whereis mysql
- mysql: /usr/lib64/mysql
- [root@localhost usr]# rm -rf /usr/lib64/mysql

[root@localhost usr]# whereis mysql
mysql: /usr/lib64/mysql
[root@localhost usr]# rm -rf /usr/lib64/mysql
rm -rf /usr/share/mysql
卸载4:
- [root@localhost usr]# rm –rf /usr/my.cnf
- [root@localhost usr]# rm -rf /root/.mysql_sercret

[root@localhost usr]# rm –rf /usr/my.cnf
[root@localhost usr]# rm -rf /root/.mysql_sercret
- [root@localhost usr]# chkconfig --list | grep -i mysql
- [root@localhost usr]# chkconfig --del mysqld

[root@localhost usr]# chkconfig --list | grep -i mysql
[root@localhost usr]# chkconfig --del mysqld
- 此处删除看自己设置:mysql/mysqld

此处删除看自己设置:mysql/mysqld
五、Centos7安装mysql:第一步查看系统有无mysql,然后删除之的更多相关文章
- CentOS7安装CDH 第一章:CentOS7系统安装
相关文章链接 CentOS7安装CDH 第一章:CentOS7系统安装 CentOS7安装CDH 第二章:CentOS7各个软件安装和启动 CentOS7安装CDH 第三章:CDH中的问题和解决方法 ...
- configure - 源代码安装的第一步
configure是源代码安装的第一步,主要的作用是对即将安装的软件进行配置,检查当前的环境是否满足要安装软件的依赖关系 configure有许多参数可配,具体参见./configure --help ...
- 配置环境是程序员的第一步 -- Windows 10 下 MySQL 安装
MySQL 作为最典型的关系型数据库管理系统,由于其体积小.速度快.总体拥有成本低,尤其是其开放源码这一特点,一般中小型网站的开发都选择 MySQL 作为网站数据库.MySQL 社区版的功能也足够我们 ...
- PHP在Windows下安装配置第一步
第一步就是下载和安装PHP解释器了: 1.下载Windows版本号的PHP解释器,下载地址:官方下载 我下载的是 VC11 x64 Thread Safe 这个以下的zip包 2.下载完毕后,解压到 ...
- [CentOS 7] 安装nginx第一步先搭建nginx服务器环境
简要地介绍一下,如何在CentOS 7中安装nginx服务器 方法/步骤 下载对应当前系统版本的nginx包(package) # wget http://nginx.org/packages/ ...
- CentOS7安装Memcached 三步曲
1.yum 安装 yum clean allyum -y updateyum -y install memcached 2.Memcached 运行 memcached -h //查看考号修改配置vi ...
- mysql 第一课 win7艰难的配置与删除注册表重新安装
mysql 这个安装一定要慎重!慎重!慎重! 重要的事情说三遍.. 不会的一定要按步骤来~出错了真的很难受. 详细教程 --> https://jingyan.baidu.com/album/ ...
- CentOS7安装CDH 第五章:CDH的安装和部署-CDH5.7.0
相关文章链接 CentOS7安装CDH 第一章:CentOS7系统安装 CentOS7安装CDH 第二章:CentOS7各个软件安装和启动 CentOS7安装CDH 第三章:CDH中的问题和解决方法 ...
- Linux系统下 MySQL 安装 指南(5.7和8.0 版本)
一. 准备工作 1 删除本地centos7中的mariadb: 查看系统中是否已安装 mariadb 服务: rpm -qa | grep mariadb 或 yum list installed | ...
随机推荐
- celery 使用 - 3
# celery 使用 1.broker 2.基础案例 使用redis作为broker和brokend. 创建tasks.py # tasks.py di = 'redis://:****@local ...
- spring中@Component注解
1.@controller 控制器(注入服务) 2.@service 业务(注入dao) 3.@repository dao(实现dao访问) 4.@component (把普通pojo实例化到spr ...
- Building Ethereum private chain on CentOS
golang安装 yum install golang 查看版本 go version 安装以太坊源代码 Building Geth (command line client) Clone the r ...
- 【PAT甲级】1082 Read Number in Chinese (25 分)
题意: 输入一个九位整数,输出它的汉字读法(用拼音表示). trick: 字符串数组""其实会输出一个空格,而不是什么都不输出,导致测试点0和4格式错误. AAAAAccepted ...
- 机器学习 — 从mnist数据集谈起
做了一些简单机器学习任务后,发现必须要对数据集有足够的了解才能动手做一些事,这是无法避免的,否则可能连在干嘛都不知道,而一些官方例程并不会对数据集做过多解释,你甚至连它长什么样都不知道... 以skl ...
- Vue-路由传参query与params
注明:vue中 $router 和 $route 的区别 //$router : 是路由操作对象,只写对象 //$route : 路由信息对象,只读对象 //操作 路由跳转 this.$router. ...
- oracle学习笔记(十四) 数据库对象 索引 视图 序列 同义词
数据库对象 用户模式:指数据库用户所创建和存储数据对象的统称.在访问其它用户模式的数据库对象时需加上用户模式. 如:scott.emp, scott.dept等. 数据库对象包括:表.视图.索引.序列 ...
- CSS样式的优先级(权重)
当使用不同的选择器选中同一个元素并设置相同样式时,这时样式间产生了冲突 最终采用的是哪个选择器? 由选择器的优先级(权重)决定,权重高的优先显示 优先级规则(多个按位置分别进行计算,不进位): 内联样 ...
- SpringBoot+MyBatis+PageHelper分页无效
POM.XML中的配置如下:<!-- 分页插件 --><!-- https://mvnrepository.com/artifact/com.github.pagehelper/pa ...
- Newtonsoft.Json小记
/*json相关*/ //http://www.cnblogs.com/hongfei/p/3593936.html string jsonObject = "{\"phone\& ...