MySQL 8.0.13 installation and configuration tutorial under CentOS7.3

MySQL 8.0.13 installation and configuration tutorial under CentOS7.3

1. Basic Environment

1. Operating system: CentOS 7.3
2. MySQL: 8.0.13 Link: https://pan.baidu.com/s/13-j_umr7eEnKFaugw4YTqQ Extraction code: 62yt

2. Install MySQL

1. Uninstall mariadb database

rpm -qa | grep mariadb
yum -y remove mariadb-libs-5.5.52-1.el7.x86_64

2. Install related dependencies (this article uses CentOS 7.3 image as local offline yum source)

yum -y install openssl-devel perl-JSON

3. Unzip and install MySQL

tar -xvf mysql-8.0.13-1.el7.x86_64.rpm-bundle.tar

rpm -ivh mysql-community-*.rpm

4. Modify the configuration file

vim /etc/my.cnf

default-storage-engine = innodb
innodb_file_per_table
collation-server = utf8_general_ci
init-connect = 'SET NAMES utf8'
character-set-server = utf8
max_allowed_packet = 100M

5. Initialize the database and start

mysqld --initialize
chown mysql:mysql /var/lib/mysql -R
systemctl start mysqld
systemctl enable mysqld

6. View the temporary password and modify the MySQL password using the temporary password

cat /var/log/mysqld.log | grep password

mysqladmin -uroot -pbga/.tkZw4q! password Test1212!

7. Grant remote user permissions

mysql -u root -p

create user 'root'@'%' identified with mysql_native_password by 'Test1212!';

grant all privileges on *.* to 'root'@'%' with grant option;

flush privileges;

8. Modify the password when logging in to localhost to prevent local login failure

mysql -uroot -p -h 192.168.0.101

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

flush privileges;

9. Modify encryption rules

The encryption rules of MySql 8.0 and 5.0 are different, and the current visualization tool only supports the old encryption method. If it is not modified, the visualization tool may not be able to open the database.

ALTER USER 'root'@'localhost' IDENTIFIED BY 'root' PASSWORD EXPIRE NEVER;

flush privileges;

Wonderful topic sharing:

MySQL different versions installation tutorial

MySQL 5.7 installation tutorials for various versions

MySQL 5.6 installation tutorials for various versions

mysql8.0 installation tutorials for various versions

The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM.

You may also be interested in:
  • MySQL 8.0.15 installation and configuration method graphic tutorial under Windows
  • MySQL 8.0.14 installation and configuration method graphic tutorial
  • The data folder failed to be created automatically during the installation of mysql8.0.14.zip. The service cannot be started.
  • MySQL 8.0.14 installation and configuration method graphic tutorial (general)
  • MySQL 8.0.13 installation and configuration method graphic tutorial
  • MySQL 8.0.13 decompression version installation and configuration method graphic tutorial
  • MySQL 8.0.13 installation and configuration method graphic tutorial under win10
  • MySQL 8.0.13 installation and configuration method graphic tutorial under Windows 64 bit
  • Detailed tutorial on installing mysql-8.0.13 (zip installation) on windows 10 system
  • MySQL 8.0.15 winx64 decompression version installation and configuration method graphic tutorial

<<:  CentOS 7.6 installation of MySQL 5.7 GA version tutorial diagram

>>:  Vue implements click feedback instructions for water ripple effect

Recommend

MySQL Quick Data Comparison Techniques

In MySQL operation and maintenance, a R&D col...

Several ways to add timestamps in MySQL tables

Scenario: The data in a table needs to be synchro...

Exploring the Linux Kernel: The Secrets of Kconfig

Get a deep understanding of how the Linux configu...

Detailed explanation of the wonderful uses of SUID, SGID and SBIT in Linux

Preface Linux's file permission management is...

Some notes on mysql create routine permissions

1. If the user has the create routine permission,...

5 solutions to CSS box collapse

First, what is box collapse? Elements that should...

Detailed explanation of the difference between docker-compose ports and expose

There are two ways to expose container ports in d...

Cross-browser development experience summary (I) HTML tags

Add a DOCTYPE to the page Since different browser...

A brief analysis of React's understanding of state

How to define complex components (class component...

HTML+CSS to achieve surround reflection loading effect

This article mainly introduces the implementation...

Some common mistakes with MySQL null

According to null-values, the value of null in My...

Detailed process of installing nginx1.9.1 on centos8

1.17.9 More delicious, really Nginx download addr...

Simple steps to configure Nginx reverse proxy with SSL

Preface A reverse proxy is a server that receives...

CSS3 flip card number sample code

I received a task from the company today, and the...