English 中文(简体)
我们可以在 Linux CentOS5. 8 上安装不同版本的 MySQL 吗?
原标题:Can we install MySQL different versions on Linux CentOS5.8?

我正在尝试安装一个软件, 需要 MySQL- server, MySQL- 客户安装在服务器上, 所以现在我要安装 MySQL- server 和 MySQL- 客户, 使用 rpm 文件“ MySQL- server-5. 5. 17-1. rhel5. x86_ 64. rpm ” 和“ MySQL- client-5. 5. 17-1.rhel5. x86_ 64. rpm ” 。

我安装了 MySQL 客户端, 但当我尝试运行 Mysql- server 时

  *rpm -i MySQL-server-5.5.17-1.rhel5.x86_64.rpm*

它显示错误 :

  *error: Failed dependencies:
     MySQL conflict with mysql-5.0.77-4.el5_6.6.x86_64
     MySQL conflict with mysql-5.0.77-4.el5_6.6.i386
     MySQL conflict with mysql-server-5.0.77-4.el5_6.6.x86_64*

那么我怎样才能解决这个问题呢?

最佳回答

第一个问题 - 是已经实际使用安装的 MySQL 版本, 还是仅仅由于新建的 CMOS 安装而安装的版本? 如果是前者, 请尝试升级而不是安装。 如果后者, 请卸载旧版本( 可能使用 < code> - no- deps 选项在 < code> prpm 上安装旧版本), 然后安装新版本

下一步, 你是要替换 MySQL, 还是要同时安装另一个版本?

如果前一版本, 如果前一版本, 再次尝试升级而不是安装。 如果这不可能, 您将不得不删除旧版本, 然后安装新版本

如果后一种选择,并且如果可能 ,请查看 RPM 中的 -prefix -relocate 选项。

如果您要努力将它与一个更年长者并肩安放,您就会有乐趣和游戏,确保相关版本指向正确的图书馆,并确保它们之间不会出现任何腐败。此外,您“坚固”需要运行它们,以便他们用不同的数据库文件夹、 PID 和套接字文件等监听不同的端口。

无论你需要做什么,都尽量多的备份,在下班时间里做

问题回答

the error given by you *error: Failed dependencies: MySQL conflict with mysql-5.0.77-4.el5_6.6.x86_64 MySQL conflict with mysql-5.0.77-4.el5_6.6.i386 MySQL conflict with mysql-server-5.0.77-4.el5_6.6.x86_64*

清晰显示您要安装的机器 安装了 Mysql 5.5 rpm 5. 077 。

to resolve this problem . 1. you take backup of datadir and my.cnf (if you are using mysql 5.0 db server earlier). 2. remove all mysql 5.0 server packages , to remove these package you should knew what are the packages already installed on machine to view all mysql package already installed use rpm -qa | grep -i "mysql*" this command show what package is already installed on machine now you have to remove all package which name shows in above command.

to remove a package/rpm use rpm -e mysql-5.0.** if show error then use rpm -e --nodeps mysql-5.0.**

我们必须使用 rpm -e 来逐个删除所有包件 。

  1. after successful remove all older version of mysql , now start installation of mysql-5.5*** packages by using rpm -ivh mysql-5.5***.rpm.




相关问题
SQL SubQuery getting particular column

I noticed that there were some threads with similar questions, and I did look through them but did not really get a convincing answer. Here s my question: The subquery below returns a Table with 3 ...

please can anyone check this while loop and if condition

<?php $con=mysql_connect("localhost","mts","mts"); if(!con) { die( unable to connect . mysql_error()); } mysql_select_db("mts",$con); /* date_default_timezone_set ("Asia/Calcutta"); $date = ...

php return a specific row from query

Is it possible in php to return a specific row of data from a mysql query? None of the fetch statements that I ve found return a 2 dimensional array to access specific rows. I want to be able to ...

Character Encodings in PHP and MySQL

Our website was developed with a meta tag set to... <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> This works fine for M-dashes and special quotes, etc. However, I ...

Pagination Strategies for Complex (slow) Datasets

What are some of the strategies being used for pagination of data sets that involve complex queries? count(*) takes ~1.5 sec so we don t want to hit the DB for every page view. Currently there are ~...

Averaging a total in mySQL

My table looks like person_id | car_id | miles ------------------------------ 1 | 1 | 100 1 | 2 | 200 2 | 3 | 1000 2 | 4 | 500 I need to ...

热门标签