MySQL installation tutorial under Centos7

Source: Internet
Author: User

MySQL installation tutorial under Centos7

The command for installing mysql is as follows:

# Wget http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm

# Rpm-ivh mysql-community-release-el7-5.noarch.rpm

# Yum install mysql-community-server

The system automatically installs the tool. Finally, a message is displayed, indicating that the installation is successful. MySQL installation tutorial under Centos7

After installation, restart the mysql service:

# Service mysqld restart

Will output: Redirecting to/bin/systemctl restart mysqld. service

Run the command # netstat-atp to check that the mysqld process has started listening:

This indicates that mysql can be used now. You can directly enter mysql to connect to the server. For details, see:

In this case, you can directly connect without entering the user and password.

Add a user's password: set password for 'root' @ 'localhost' = password ('xxx ');

Then you need to enter the password to connect to the database:

Related Article

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.