Centos7 install MySQL via yum and authorize remote connection

Source: Internet
Author: User

Installation:

There is no normal installation of MySQL Mysql-sever files in the CentOS 7 yum source, which needs to be downloaded from the official website ( by installing MySQL's yum container and installing MySQL via Yum)

Note: Before installing, you need to uninstall all MARIADB software (fully compatible with MySQL's other database, written by MySQL creator), by ordering Yum Remove mariadb*

Get Yum Address:



Install the Yum container for MySQL:


The fact is that two container files have been added under/etc/yum.repo.d/:



Check out what the Yum container has MySQL software (yum install mysql-and press TAB two times , note: When using Yum, yum downloads the container's list to the/var/cache/yum inside the machine, But the MySQL container is just added,/var/cache/yum inside has not been downloaded, so yum install mysql- here and press two times tab , should not appear below the screen,

so you can enter:yum list mysql-community-client, load container list to/var/cache/yum, enter yum install mysql- Press the TAB key two more times here :



Here I have installed these:



After the installation is complete, start MySQL:



Set Password:



Authorized Remote access: Login:

Using the MySQL database (the real database, not the database software), all permissions for all tables (*. *) for all databases (all privileges) are granted to the root user accessed through any IP (%), the password is 123456, and the last flush privileges).

Open firewall port: Use Vim to modify/etc/sysconfig/iptables, add a line (here is to simply add a row, more firewall knowledge please learn by yourself):


To restart the firewall:



Under Windows, I tested with Navicat:


The remote connection was successful.



From for notes (Wiz)

Centos7 install MySQL via yum and authorize remote connection

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.