无法通过 RPM 安装 MySQL 5.6 [英] Can't install MySQL 5.6 by RPM
问题描述
我正在尝试从我下载的 RPM 包中安装 MySQL 5.6 社区版.我在 cloudera 的 CDH 4.5 虚拟机上运行,它是 CentOS 6.4.VM 安装了 MySQL 5.1.73,旧版本的文件似乎阻止我更新.
I'm trying to install MySQL 5.6 community edition from the RPM package I downloaded. I'm running on cloudera's CDH 4.5 virtual machine, which is CentOS 6.4. The VM came with MySQL 5.1.73 installed, the old versions of files seem to be blocking me from updating.
我已经这样做了:
sudo yum remove mysql
而且效果很好,没有问题.然后我删除了/usr/lib/mysql 中的所有内容,也就是数据目录.然后我尝试安装新版本:
and that worked just fine, without a problem. Then I deleted everything in /usr/lib/mysql, aka the data directory. So then I tried installing the new version:
[cloudera@localhost mysql]$ pwd
/home/cloudera/mysql
[cloudera@localhost mysql]$ ll
total 302660
-rw-r--r-- 1 cloudera cloudera 23080383 Mar 17 02:39 MySQL-client-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 4573735 Mar 17 02:40 MySQL-devel-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 114192347 Mar 17 02:40 MySQL-embedded-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 86961692 Mar 17 02:41 MySQL-server-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 2398671 Mar 17 02:41 MySQL-shared-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 5180653 Mar 17 02:41 MySQL-shared-compat-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 73530987 Mar 17 02:42 MySQL-test-5.6.17-1.linux_glibc2.5.x86_64.rpm
[cloudera@localhost mysql]$ sudo yum install MySQL-server-5.6.17-1.linux_glibc2.5.x86_64.rpm
.....
Downloading Packages:
Running rpm_check_debug
Running Transaction Test
Transaction Check Error:
file /usr/share/mysql/charsets/README from install of MySQL-server-5.6.17-1.linux_glibc2.5.x86_64 conflicts with file from package mysql-libs-5.1.73-3.el6_5.x86_64
file /usr/share/mysql/czech/errmsg.sys from install of MySQL-server-5.6.17-1.linux_glibc2.5.x86_64 conflicts with file from package mysql-libs-5.1.73-3.el6_5.x86_64
......
所以看起来旧的安装阻止了我,我试图删除 mysql-libs 但是...
So it looks like the old installation is blocking me, I tried to delete mysql-libs but...
[cloudera@localhost mysql]$ sudo yum remove mysql-libs
.....
pig noarch 0.11.0+33-1.cdh4.4.0.p0.14.el6 @cloudera-cdh4 120 M
postfix x86_64 2:2.6.6-2.2.el6_1 @anaconda-CentOS-201112091719.x86_64/6.2 9.7 M
redhat-lsb x86_64 4.0-7.el6.centos @base 0.0
redhat-lsb-compat x86_64 4.0-7.el6.centos @base 0.0
redhat-lsb-core x86_64 4.0-7.el6.centos @base 22 k
redhat-lsb-graphics x86_64 4.0-7.el6.centos @base 0.0
redhat-lsb-printing x86_64 4.0-7.el6.centos @base 0.0
solr noarch 4.4.0+69-1.cdh4.3.0.p0.4.el6 @cloudera-search 66 M
solr-mapreduce noarch 1.0.0-1.cdh4.3.0.p0.5.el6 @cloudera-search 55 M
sqoop noarch 1.4.3+62-1.cdh4.4.0.p0.15.el6 @cloudera-cdh4 7.7 M
sqoop2 noarch 1.99.2+85-1.cdh4.4.0.p0.62.el6 @cloudera-cdh4 7.8 M
sysstat x86_64 9.0.4-20.el6 @base 807 k
tomcat noarch 7.0.33-3.el6 @epel 303 k
Transaction Summary
=============================================================================================================================================================================================
Remove 67 Package(s)
它列出了许多依赖于 mysql-libs 的主要软件.我不想重新安装 tomcat、pig、hive、mahout、hue、oozie、flume 和 cloudera manager.我以前曾与它们合作过,我知道它们是正确安装和配置的噩梦,所以我真的不想卸载它们.
It went and listed a lot of major software that depends on mysql-libs. I don't want to reinstall tomcat, pig, hive, mahout, hue, oozie, flume, and cloudera manager. I have worked with those before, I know that they are a NIGHTMARE to get installed and configured correctly, so I really don't want to uninstall those.
所以我想也许我应该尝试更新,
So I thought maybe I should try an update instead,
[cloudera@localhost mysql]$ sudo yum update MySQL-server-5.6.17-1.linux_glibc2.5.x86_64.rpm
....
Examining MySQL-server-5.6.17-1.linux_glibc2.5.x86_64.rpm: MySQL-server-5.6.17-1.linux_glibc2.5.x86_64
Package MySQL-server not installed, cannot update it. Run yum install to install it instead.
No Packages marked for Update
它不会让我更新它,因为我已经删除了它.
It will not let me update it because I already removed it.
有人能告诉我如何从这些 RPM 安装 MySQL 而不卸载其他所有东西吗?
Would somebody please tell me how to install MySQL from these RPMs without uninstalling everything else?
推荐答案
尝试安装 shared-compat
包,如您所见 此处.
Try to install shared-compat
packages as you can see here.
这篇关于无法通过 RPM 安装 MySQL 5.6的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!