CentOS 7.6 installation of MySQL 5.7 GA version tutorial diagram

CentOS 7.6 installation of MySQL 5.7 GA version tutorial diagram

Environment Preparation

Uninstall mariadb

rpm -qa | grep mariadb
rpm -e --nodeps mariadb-libs-5.5.60-1.el7_5.x86_64

CentOS 7.6 has mariadb integrated inside, and installing mysql will conflict with mariadb files, so you need to uninstall mariadb first.

Install MySQL

Get the yum source (MySQL official website)

Install yum source

rpm -Uvh https://dev.mysql.com/get/mysql80-community-release-el7-3.noarch.rpm

Check the startup status of each version

yum repolist all | grep mysql

The latest version 8.0 is enabled by default

Disable 8.0 and enable 5.7

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

The command is in the yum-utils package. Installing it can solve the problem of not being able to find the yum-config-manager command:

yum -y install yum-utils

Install mysqll

yum -y install mysql-community-server

Configure MySQL remote connection

Check the MySQL version

mysql -V

Start mysql && set it to start automatically

systemctl start mysqld
systemctl enable mysqld

View the default generated password

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

Login to change password

mysql -uroot -p

Change Password

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

MySQL 5.7 has a password security check plug-in (validate_password) installed by default. The default password check policy requires that the password must contain uppercase and lowercase letters, numbers, and special symbols, and the length must not be less than 8 characters. Otherwise, the error message ERROR 1819 (HY000): Your password does not satisfy the current policy requirements will be displayed.

Authorize remote login users

GRANT ALL PRIVILEGES ON *.* TO 'noneplus'@'%' IDENTIFIED BY 'Noneplus564925080!' WITH GRANT OPTION;
flush privileges;

Open server port 3306

remote connection

Summarize

The above is the tutorial illustration of installing MySQL 5.7 GA version on CentOS 7.6 introduced by the editor. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website!
If you find this article helpful, please feel free to reprint it and please indicate the source. Thank you!

You may also be interested in:
  • Detailed tutorial on installing MySQL 5.7.6+ from source in CentOS 7
  • Detailed tutorial on installing mysql 8.0.13 (rpm) on Centos7
  • How to install mysql5.7.24 binary version on Centos 7 and how to solve it
  • Detailed installation tutorial of mysql 5.7 under CentOS 6 and 7
  • CentOS7 uses yum to install mysql 8.0.12
  • Detailed tutorial on installing MySQL 8.0 from source code on CentOS 7.4
  • Installation tutorial of mysql8.0rpm on centos7
  • Tutorial on installing lnmp using yum on centos7 (linux+nginx+php7.1+mysql5.7)

<<:  Vue implements upload component

>>:  MySQL 8.0.13 installation and configuration tutorial under CentOS7.3

Recommend

Reasons and methods for Waiting for table metadata lock in MySQL

When MySQL performs DDL operations such as alter ...

How to install and configure WSL on Windows

What is WSL Quoting a passage from Baidu Encyclop...

How to decrypt Linux version information

Displaying and interpreting information about you...

Summary of how to modify the root password in MySQL 5.7 and MySQL 8.0

MySQL 5.7 version: Method 1: Use the SET PASSWORD...

An example of implementing a simple infinite loop scrolling animation in Vue

This article mainly introduces an example of Vue ...

Linux checkup, understand your Linux status (network IO, disk, CPU, memory)

Table of contents 1. Core commands 2. Common comm...

Summary of some efficient magic operators in JS

JavaScript now releases a new version every year,...

Vue3 manual encapsulation pop-up box component message method

This article shares the specific code of Vue3 man...

JavaScript form validation example

HTML forms are commonly used to collect user info...

How to get form data in Vue

Table of contents need Get data and submit Templa...

HTML input file control limits the type of uploaded files

Add an input file HTML control to the web page: &...

How to add java startup command to tomcat service

My first server program I'm currently learnin...

js array entries() Get iteration method

Table of contents 1. Detailed syntax of entires()...

Get the calculated style in the CSS element (after cascading/final style)

To obtain the calculated style in a CSS element (t...