Install mysql5.7 on centos7.2

一、Download MySQL Yum Repositorymysql

  https://dev.mysql.com/downloads/repo/yum/sql

wget https://dev.mysql.com/get/mysql57-community-release-el7-11.noarch.rpmide

二、Adding the MySQL Yum Repositoryui

  yum install -y mysql57-community-release-el7-11.noarch.rpmspa

 

or  rpm -Uvh mysql57-community-release-el7-11.noarch.rpm3d

 三、Selecting a Release Series server

  the latest GA release of MySQL is selected for installation by default  mysql57-communityblog

yum repolist enabled | grep mysqltoken

enable the subrepository for the specific series(mysql56-community)ci

  yum-config-manager --disable mysql57-community
  yum-config-manager --enable mysql56-community

OR change enabled=1 option of repo file

四、Installing MySQL

yum install -y  mysql-community-server

五、Starting the MySQL Server

  systemctl start mysqld

六、find&change mysql passwd

grep 'temporary password' /var/log/mysqld.log

mysql -uroot -p

ALTER USER 'root'@'localhost' IDENTIFIED BY 'MyNewPass4!';

七、mysql-yum-repo-quick-guide

https://dev.mysql.com/doc/mysql-yum-repo-quick-guide/en/

相關文章
相關標籤/搜索