How to Install MySQL 5.6 on CentOS 7 by using yum command? yum install MySQL 5.6 server ,follow the given below steps.
step1: download the yum repository rpm package.
- yum install http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm
 
 
 
step2: Check the MySQL 5.6 RPM package is available,using yum repolist enabled command. as follows:
- [root@VM_230_32_centos ~]# sudo yum repolist enabled | grep "mysql.*-community.*"
 
- Repository epel is listed more than once in the configuration
 
- mysql-connectors-community/x86_64 MySQL Connectors Community                  42
 
- mysql-tools-community/x86_64      MySQL Tools Community                       53
 
- mysql56-community/x86_64          MySQL 5.6 Community Server                 361
 
 
 
step3: Now, you can type in the following commands to install MySQL 5.6.
- yum install mysql-community-server
 
 
 
output: it's success!
- .......
 
- Replaced:
 
-   mariadb-libs.x86_64 1:5.5.52-1.el7                                                                                                                                                                                           
 
- Complete!
 
- [root@VM_230_32_centos ~]#
 
 
 
step4: Start MySQL 5.6 using the following command:
- //on centos 7.x
 
- systemctl start mysqld
 
- systemctl restart mysqld
 
- systemctl stop mysqld
 
 
- //on centos 6.x
 
- service mysqld start
 
- service mysqld restart
 
- service mysqld stop
 
 
 
step5: Login into mysql server. Because it is freshly installed hence root password is blank(MySQL 5.7 server initial password is not empty)
- //login
 
- [root@VM_219_180_centos ~]# mysql -uroot -p
 
- //you could reset mysql server password, as follows.
 
- mysql> set password for root@localhost = password('123456');
 
 
 
thanks!
 
 
No comments:
Post a Comment
Note: only a member of this blog may post a comment.