Redhat 7 install MySQL community server

Here’s a basic tutorial for installing MySQL community server to Redhat enterprise linux

Upgrade RPM package

sudo rpm -Uvh https://repo.mysql.com//mysql80-community-release-el7-3.noarch.rpm

Enable repository and install MySQL community version

yum --enablerepo=mysql80-community install mysql-community-server
# Start MySQL server
systemctl start mysqld
# Check MySQL server status
systemctl status mysqld

Once you have MySQL installed, next step is to initialize database

# Get generated root password
sudo grep 'temporary password' /var/log/mysqld.log
# Log in with temporary password and update root password
mysql -uroot -p 
ALTER USER 'root'@'localhost' IDENTIFIED BY 'YourNewPassw0rd';

Now you should be ready to use MySQL database.

Reference:

https://dev.mysql.com/doc/refman/8.0/en/linux-installation-yum-repo.html

Leave a Comment

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.

Scroll to Top