Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Centos7 install mysql5.7

2025-04-07 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

System environment: Centos7.4

The steps to build are as follows:

1. First go to the source file directory of this machine

[root@edu-mycat-01 ~] # cd / usr/local/src/

two。 Use wget to download the rpm package of the official Yum source:

[root@edu-mycat-01 src] # wget https://dev.mysql.com/get/mysql57-community-release-el7-11.noarch.rpm

3. Install the RPM package

Uninstall the original package mariadb-libs first

[root@edu-mycat-01 src] # yum remove mariadb-libs-y

[root@edu-mycat-01 src] # rpm-ivh mysql57-community-release-el7-11.noarch.rpm

4. Use yum again to install mysql-serve

[root@edu-mycat-01 ~] # yum-y install mysql-community-server

Check to see if it started successfully:

[root@edu-mycat-01 ~] # ps-aux | grep mysqld

5. Set the mysqld service to boot automatically:

[root@edu-mycat-01 ~] # systemctl enable mysqld

6. Log in with the initial password

[root@edu-mycat-01 ~] # cat / var/log/mysqld.log | grep'A temporary password'

[root@edu-mycat-01] # mysql-uroot-p

Reason for error: (password is too simple)

Mysql > set global validate_password_policy=0

Mysql > set global validate_password_length=1

Mysql > set global validate_password_mixed_case_count=2

Mysql > alter user 'root'@'localhost' identified by' mysqlpasswd'

Log back in successfully and complete the installation!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report