CentOS Install MySQL

Source: Internet
Author: User

1. System

The premise is to see if the server has a database, the code is as follows:
Rpm-qa |grep "MySQL", if there will be shown below the interface!

2. Database Installation Site
#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

3. After successful installation, restart MySQL, the code is as follows
#service mysqld Restart

4. The root account does not have a password after installing MySQL for the first time
Enter the command to start MySQL:
#mysql-uroot
5. To modify the MySQL password, you need to log in to MySQL first, the command after login:
Mysql>set password for ' root ' @ ' localhost ' =password (' newpassword ');
6. View the database encoding:
Mysql>status

7. Modify the encoding format of the database client (other encoding formats are as follows):
Mysql> set Character_set_client=utf8;

8. The database opens a remote connection:
Mysql>grant all privileges The "root" @ '% ' identified by ' 123456 ' with grant option; (Root is username,% is any host, 123456 is the password for the remote connection)
Mysql>flush privileges; (Overloaded system permissions)
mysql>exit;

9. Open 3306 Ports:
Can check online, this method has many kinds of

This blog was posted on Csdn and is now published here for multi-platform communication.

* * Reference URL

Http://www.cnblogs.com/starof/p/4680083.html

CentOS Install 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.