[root@localhost tmp]# rpm -qa |grep -i mysql
perl-DBD-MySQL-4.013-3.el6.x86_64
qt-mysql-4.6.2-20.el6.x86_64
mysql-libs-5.1.52-1.el6_0.1.x86_64
mysql-5.1.52-1.el6_0.1.x86_64
mysql-server-5.1.52-1.el6_0.1.x86_64
[root@localhost tmp]# rpm -ev mysql-devel-5.1.52-1.el6_0.1.x86_64
error: package mysql-devel-5.1.52-1.el6_0.1.x86_64 is not installed
perl-DBD-MySQL-4.013-3.el6.x86_64
qt-mysql-4.6.2-20.el6.x86_64
mysql-libs-5.1.52-1.el6_0.1.x86_64
mysql-5.1.52-1.el6_0.1.x86_64
mysql-server-5.1.52-1.el6_0.1.x86_64
[root@localhost tmp]# rpm -ev mysql-devel-5.1.52-1.el6_0.1.x86_64
error: package mysql-devel-5.1.52-1.el6_0.1.x86_64 is not installed
解决方案
5
which mysql
5
提示得很明白啊,已安装组件是
perl-DBD-MySQL-4.013-3.el6.x86_64
qt-mysql-4.6.2-20.el6.x86_64
mysql-libs-5.1.52-1.el6_0.1.x86_64
mysql-5.1.52-1.el6_0.1.x86_64
mysql-server-5.1.52-1.el6_0.1.x86_64
而你卸载的是mysql-devel-5.1.52-1.el6_0.1.x86_64,当然会提示 not installed错误。
perl-DBD-MySQL-4.013-3.el6.x86_64
qt-mysql-4.6.2-20.el6.x86_64
mysql-libs-5.1.52-1.el6_0.1.x86_64
mysql-5.1.52-1.el6_0.1.x86_64
mysql-server-5.1.52-1.el6_0.1.x86_64
而你卸载的是mysql-devel-5.1.52-1.el6_0.1.x86_64,当然会提示 not installed错误。
5
对的
5
什么意思?
15
用组件名强行卸载就行,例如
rpm -e –nodeps mysql-libs-5.1.52-1.el6_0.1.x86_64
rpm -e –nodeps mysql-server-5.1.52-1.el6_0.1.x86_64
MySQL在Linux上是由很多组件构成的,每个组件都要单独卸载,不像Windows执行一次卸载就完了
另外卸载完了记得把MySQL的数据文件给删除,要是没改过,默认是/var/lib/mysql和/usr/share/mysql
rpm -e –nodeps mysql-libs-5.1.52-1.el6_0.1.x86_64
rpm -e –nodeps mysql-server-5.1.52-1.el6_0.1.x86_64
MySQL在Linux上是由很多组件构成的,每个组件都要单独卸载,不像Windows执行一次卸载就完了
另外卸载完了记得把MySQL的数据文件给删除,要是没改过,默认是/var/lib/mysql和/usr/share/mysql
5
建议 重新将全部mysq相关的东西全部卸载,然后重新安装MySQL,定能解决问题