How to Install MySQL 5.6 on CentOS 6.7

How to Install MySQL 5.6 on CentOS 6.7

This article will show you how to install MySQL 5.6 on CentOS 6.7.

 

In writing this how-to, I have assumed that you are running a stock installation of CentOS 6.7, and that you DO NOT already have MySQL installed.

 

1. Install the MySQL Community repository

 

First, we need to install the Official MySQL Community repository, this is done by entering the following commands:

 

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

rpm -Uvh mysql-community-release-el6-5.noarch.rpm

 

You should now be ready to install MySQL 5.6!

 

2. Installing MySQL 5.6

 

Type in the following commands to install MySQL 5.6

 

yum -y install mysql mysql-server

 

Type in the below to verify the correct packages were installed:

 

rpm -qa | grep mysql

 

The output should look similar to the following:

 

mysql-community-release-el6-5.noarch
mysql-community-common-5.6.27-2.el6.x86_64
mysql-community-client-5.6.27-2.el6.x86_64
mysql-community-server-5.6.27-2.el6.x86_64
mysql-community-libs-5.6.27-2.el6.x86_64
mysql-community-libs-compat-5.6.27-2.el6.x86_64

 

Now you can start MySQL 5.6 using the following command:

 

chkconfig mysqld on
service mysqld start

 

Verify that MySQL 5.6 is running:

 

mysql -v

 

And you should see output similar to the following:

 

Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.6.27 MySQL Community Server (GPL)

 

That’s all she wrote!

 

Upgrading from MySQL 5.5 is a fairly easy process, and I’ll be writing a guide on that soon. However, upgrading from earlier versions of MySQL (such as MySQL 5.1) requires a bit more work. I’ll see writing on article on How to Upgrade MySQL 5.1 to MySQL 5.6 on CentOS 6.7 so stay tuned!

發表迴響

你的電子郵件位址並不會被公開。 必要欄位標記為 *