当前位置: 首页 > 面试题库 >

在CentOS 6.2中将MySQL版本从5.1更新到5.5

阎嘉荣
2023-03-14
问题内容

我试图在CentOS 6.2中将MySQL从5.1更新到5.5。以下是我执行的过程:

1. rpm -Uvh http://repo.webtatic.com/yum/centos/5/latest.rpm
2. yum install libmysqlclient15 --enablerepo=webtatic
3. yum remove mysql mysql-*
4. yum install mysql55 mysql55-server --enablerepo=webtatic

当我尝试第四步时,得到以下输出:

[root@d2005 /]# yum install mysql55 mysql55-server --enablerepo=webtatic
Failed to set locale, defaulting to C
Loaded plugins: fastestmirror, presto
Loading mirror speeds from cached hostfile
 * base: yum.singlehop.com
 * extras: centos.mirrors.tds.net
 * updates: pubmirrors.reflected.net
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package mysql55.x86_64 0:5.5.10-1.w5 will be installed
--> Processing Dependency: mysql55-libs = 5.5.10-1.w5 for package: mysql55-5.5.10-1.w5.x86_64
---> Package mysql55-server.x86_64 0:5.5.10-1.w5 will be installed
--> Processing Dependency: perl-DBD-MySQL for package: mysql55-server-5.5.10-1.w5.x86_64
--> Running transaction check
---> Package mysql55-libs.x86_64 0:5.5.10-1.w5 will be installed
---> Package perl-DBD-MySQL.x86_64 0:4.013-3.el6 will be installed
--> Processing Dependency: libmysqlclient.so.16(libmysqlclient_16)(64bit) for package: perl-DBD-MySQL-4.013-3.el6.x86_64
--> Processing Dependency: libmysqlclient.so.16()(64bit) for package: perl-DBD-MySQL-4.013-3.el6.x86_64
--> Running transaction check
---> Package mysql-libs.x86_64 0:5.1.61-1.el6_2.1 will be installed
--> Processing Conflict: mysql55-libs-5.5.10-1.w5.x86_64 conflicts mysql-libs < 5.5.10
--> Finished Dependency Resolution
Error: mysql55-libs conflicts with mysql-libs
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

如何解决?


问题答案:

列出旧的MySql

yum list installed | grep -i mysql

删除旧的MySql

yum remove mysql mysql-*

Remi对CentOS 6和Red Hat(RHEL)6的依赖性

rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm

rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm

安装MySQL服务器

yum --enablerepo=remi,remi-test install mysql mysql-server

列出新的MySql

yum list installed | grep -i mysql

启动MySql服务器

/etc/init.d/mysqld start ##更新后使用重新启动

要么

service mysqld start ##更新后使用重新启动

chkconfig --levels 235 mysqld on

持续

mysql_upgrade -u root -p

现在我的MySql版本是5.5.32

http://www.webtatic.com/packages/mysql55/

http://www.if-not-true-then-false.com/2010/install-mysql-on-fedora-centos-
red-hat-rhel/

希望对你有所帮助

注意: 从@pim添加评论(以评论为准)

Just wanted to add that after the upgrade, my crontab was removed as well. Had to reinstall with "yum install vixie-cron" (CentOS 6)


 类似资料:
  • 本文向大家介绍linux下安装升级mysql到新版本(5.1-5.7),包括了linux下安装升级mysql到新版本(5.1-5.7)的使用技巧和注意事项,需要的朋友参考一下 今天需要把linux服务器上的mysql版本从5.1更新到5.7,那么以下内容作为记录,提供以后安装使用手册 第一步:检查linux的操作系统版本 第二步:在mysql官网上下载5.7的版本 http://dev.mysql

  • 几天前,我在play store上发布了Flatter android应用程序,现在我想在play store中更新该应用程序,因此对代码进行了更改,但现在我很困惑,我是否必须使用与第一次发布应用程序时相同的过程来生成新密钥(生成密钥,然后运行Flatter build应用程序包),还是必须遵循其他程序。请帮忙,万分感谢。

  • 3.8. 更新go到新版本 当有新版本发布的时候,会在Go Nuts邮件列表中通知。可以用以下命令获取最新的发布版本: $ cd go/src $ hg pull $ hg update release $ ./all.bash

  • 我从Spring Boot 1.5更新到2。和其他一些一样,我还面临这样一个问题,即通过进行更新,Flyway也从3更新到5。Flyway更新的问题是flyway模式表不会自动迁移,因此数据库迁移不起作用。 《Spring Boot迁移指南》建议先更新到Flyway 4,然后再更新到Spring Boot 2。我按照建议做了,包括 进入我的POM。Flyway表示,只需运行应用程序即可应用从版本3

  • 问题内容: 我正在尝试使用CocoaPods将Swift项目更新为Firebase的新SDK版本4.0.0(如文档所建议),但是即使按照文档中的步骤进行操作,更新的SDK似乎也没有安装。 谁能帮助我了解为什么这不起作用以及我如何才能更新到新的Firebase SDK? 我的Podfile 当我运行时,我得到了看似有希望的输出(除了它不是 我认为 应该的版本4 ): 我可以说它也不会更新到最新的SD

  • 问题内容: 我在安装项目时遇到了一些问题。 我拥有运行 Swift 3* 的最新版本的 Xcode ,并且当我尝试安装alamofire时遇到800个编译器错误。 * 显然地 构建Alamofire 4.0.0+需要CocoaPods 1.1.0+ 我看着终端机上的CocoaPods版本,它说我的版本是1.0.1。 我猜运行更新没有用,因为CocoaPods 1.1是beta版。 因此,我不确定如