1.安装包准备
2.按顺序安装以下安装包
一定要按顺序安装,因为前面的包是后面包的依赖
[root@iz2ze1bzpi3orra8lboxqiz mysql]#rpm -ivh Percona-Server-56-debuginfo-5.6.24-rel72.2.el6.x86_64.rpm
[root@iz2ze1bzpi3orra8lboxqiz mysql]# rpm -ivh Percona-Server-shared-56-5.6.24-rel72.2.el6.x86_64.rpm
[root@iz2ze1bzpi3orra8lboxqiz mysql]# rpm -ivh Percona-Server-client-56-5.6.24-rel72.2.el6.x86_64.rpm
[root@iz2ze1bzpi3orra8lboxqiz mysql]# rpm -ivh Percona-Server-server-56-5.6.24-rel72.2.el6.x86_64.rpm
安装第四个rpm包时可能会报错
3.报错解决
error: Failed dependencies:
libaio.so.1()(64bit) is needed by Percona-Server-server-56-5.6.24-rel72.2.el6.x86_64
libaio.so.1(LIBAIO_0.1)(64bit) is needed by Percona-Server-server-56-5.6.24-rel72.2.el6.x86_64
libaio.so.1(LIBAIO_0.4)(64bit) is needed by Percona-Server-server-56-5.6.24-rel72.2.el6.x86_64
原因:这是因为缺少libaio包的依赖
解决:安装libaio包
[root@iz2ze1bzpi3orra8lboxqiz mysql]#rpm -ivh libaio-0.3.107-10.el6.x86_64.rpm
安装完成libaio包之后,重新安装第四个安装包,看是否成功。
[root@iz2ze1bzpi3orra8lboxqiz mysql]# rpm -ivh libaio-0.3.107-10.el6.x86_64.rpm
可能会报错
error: Failed dependencies:
perl(Data::Dumper) is needed by Percona-Server-server-56-5.6.24-rel72.2.el6.x86_64
原因:这是因为缺少perl包
解决:安装autoconf
[root@iz2ze1bzpi3orra8lboxqiz mysql]# yum -y install autoconf
继续安装第四个安装包
[root@iz2ze1bzpi3orra8lboxqiz mysql]# rpm -ivh Percona-Server-server-56-5.6.24-rel72.2.el6.x86_64.rpm
结果又报错
file /usr/lib64/mysql/plugin/dialog.so from install of Percona-Server-server-56-5.6.24-rel72.2.el6.x86_64 conflicts with file from package mariadb-libs-1:5.5.60-1.el7_5.x86_64
原因:系统已经安装了其他版本的mysql-libs包和mysql数据库文件导致不兼容。
解决:删除这个数据库
[root@iz2ze1bzpi3orra8lboxqiz mysql]#yum remove mysql-libs
继续安装第四个rpm包,成功!
[root@iz2ze1bzpi3orra8lboxqiz mysql]# rpm -ivh Percona-Server-server-56-5.6.24-rel72.2.el6.x86_64.rpm
4.安装后检查
(1)检查/etc/f存在不存在
(2)检查/var/lib/mysql目录中有没有mysql数据文件
5.启动MySQL服务
启动
[root@iz2ze1bzpi3orra8lboxqiz etc]# service mysql start
Starting MySQL (Percona Server). [ OK ]
检查
[root@iz2ze1bzpi3orra8lboxqiz etc]# service mysql status
MySQL (Percona Server) running (2205) [ OK ]
停止
[root@iz2ze1bzpi3orra8lboxqiz etc]# service mysql stop
Shutting down MySQL (Percona Server)... [ OK ]
重启
[root@iz2ze1bzpi3orra8lboxqiz etc]# service mysql restart
MySQL (Percona Server) PID file could not be found! [FAILED]
Starting MySQL (Percona Server). [ OK ]
如果觉得《mysql数据库rpm包安装_Linux rpm包安装MySQL数据库问题总结》对你有帮助,请点赞、收藏,并留下你的观点哦!