admin/ May 26, 2018/ Linux/ 0 comments

HowTo Install MySQL-Server 8.0 on CentOS7 / Red Hat Enterprise Linux 7 / Oracle Linux 7 (Architecture Independent), RPM Package.
The MySQL Yum repository provides a simple and convenient way to install and update MySQL products with the latest software packages using Yum.

The MySQL Yum repository provides MySQL packages the following Linux Distros:

Red Hat Enterprise Linux / Oracle Linux
Fedora
The MySQL Yum repository includes the latest versions of:

MySQL 8.0 (GA)
MySQL 5.7 (GA)
MySQL 5.6 (GA)
MySQL 5.5 (GA – Red Hat Enterprise Linux and Oracle Linux Only)
MySQL Cluster 7.5 (GA)
MySQL Cluster 7.6 (Development)
MySQL Workbench
MySQL Fabric
MySQL Router (GA and preview)
MySQL Utilities
MySQL Connector / ODBC
MySQL Connector / Python
MySQL Connector / Java
MySQL Shell (GA and preview)

To Install on CentOs7/RHEL7 via Yum Repositories. Please follow the below steps.

Upgrade the Yum Repositories Packages.

sudo yum update -y

Install RPM package

sudo yum install -y https://dev.mysql.com/get/mysql80-community-release-el7-1.noarch.rpm

Install MySQL server on machine

sudo yum install -y mysql-server

MySQL enable mysql_native_password

echo "default-authentication-plugin=mysql_native_password" >> /etc/my.cnf

Enable on boot MySQL server and start on Machine.

sudo systemctl enable mysqld.service && sudo systemctl start mysqld.service

To Get the temperory password use the below command.

sudo cat /var/log/mysqld.log | grep "temporary password" | awk '{print $13}'

Start the MySQL Secure Installation.

mysql_secure_installation

OutPut-:

Securing the MySQL server deployment.

Enter password for user root:

The existing password for the user account root has expired. Please set a new password.
New password:

Re-enter new password:

Estimated strength of the password: 100
Do you wish to continue with the password provided?(Press y|Y for Yes, any other key for No) : y
By default, a MySQL installation has an anonymous user,
allowing anyone to log into MySQL without having to have
a user account created for them. This is intended only for
testing, and to make the installation go a bit smoother.
You should remove them before moving into a production
environment.

Remove anonymous users? (Press y|Y for Yes, any other key for No) : y
Success.


Normally, root should only be allowed to connect from
'localhost'. This ensures that someone cannot guess at
the root password from the network.

Disallow root login remotely? (Press y|Y for Yes, any other key for No) : y
Success.

By default, MySQL comes with a database named 'test' that
anyone can access. This is also intended only for testing,
and should be removed before moving into a production
environment.


Remove test database and access to it? (Press y|Y for Yes, any other key for No) : y
 - Dropping test database...
Success.

 - Removing privileges on test database...
Success.

Reloading the privilege tables will ensure that all changes
made so far will take effect immediately.

Reload privilege tables now? (Press y|Y for Yes, any other key for No) : y
Success.

All done!

 

Reference URL-: https://dev.mysql.com/downloads/repo/yum/

Share this Post

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.