Centos7安装mysql缺乏yum源怎么安装

找到mysql5.6的centos的repo源,终于解决mysql的安装问题:

1.确保centos安装了wget,没有的话安装wget

 
1
yum install wget

2.下载mysql的repo源

 
1
wget http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm

3.安装mysql-community-release-el7-5.noarch.rpm包

 
1
rpm -ivh mysql-community-release-el7-5.noarch.rpm

4.安装这个包后,会获得两个mysql的yum repo源

 
1
2
3
4
[root@localhost ~]# ls -1 /etc/yum.repos.d/mysql-community*
/etc/yum.repos.d/mysql-community.repo
/etc/yum.repos.d/mysql-community-source.repo
[root@localhost ~]#

5.然后安装mysql

 
1
yum install mysql-server
posted @ 2015-11-02 19:18  李涛军  阅读(406)  评论(0编辑  收藏  举报