Centos7 installing MySQL

Source: Internet
Author: User
Tags mysql command line

The first thing to think of is the installation of VMware Tools, after the installation is successful, the shared folder is always reported in this error.

Helpless, had to find another way to him.

Then I thought about it, made an ISO image, then mounted it on CDROM, and then installed the JDK successfully, but the MySQL installation failed, possibly because the server was downloaded from the official web only, not the dependencies.

Finally, find the mysql5.6 centos repo source and finally solve the MySQL installation problem:

1. Make sure CentOS is installed with wget, without installing wget

Yum Install wget

2. Download the MySQL repo source

wget http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm

3. Install the MYSQL-COMMUNITY-RELEASE-EL7-5.NOARCH.RPM package

RPM-IVH mysql-community-release-el7-5.noarch.rpm

4. After installing this package, you will get two MySQL yum repo source

[Email protected] ~]# ls-1/ETC/YUM.REPOS.D/MYSQL-COMMUNITY*/ETC/YUM.REPOS.D/MYSQL-COMMUNITY.REPO/ETC/YUM.REPOS.D /mysql-community-source.repo[[email protected] ~]#

5. Then install MySQL

Yum Install Mysql-server

Install according to the steps can be, but after the installation is complete, no password, need to recharge the password:

Mysql_secure_installation

You can reset the password according to this command. You can also log in to MySQL and reset

Mysql-u Root

Change according to the MySQL command line:

mysql> use mysql;mysql> Update user set Password=password ("Give-new-root-password") where user= ' ROOT ';mysql> Flush Privileges;mysql> Quit

Centos7 installing MySQL

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.