MySQL Remote connection settings

Source: Internet
Author: User
Tags mysql create

1.mysql Create remote login user and authorize:

Grant all privileges the discuz.* to [e-mail protected] ' 123.123.123.123 ' identified by ' 123456 ';

All parameters are analyzed below:

All privileges means giving all permissions to the specified user, which can also be replaced by assigning a specific permission, such as: Select,insert,update,delete,create,drop, and so on, with the "," half-width comma separated by the specific permissions.

Discuz.* means that the above permissions are for which table, discuz refers to the database, followed by the * for all tables, it can be inferred that: for all of the database is authorized as "*. *" For all tables, the entire table for a database is authorized as "database name. *", A table for a database is authorized as the database name. Table name.

Ted indicates which user you want to authorize, and this user can be either an existing user or a non-existent user.

123.123.123.123 represents the IP address that allows remote connections, or "%" if you want to limit the IP of the link.

123456 is the user's password.

After executing the above statement, execute the following statement before it can take effect immediately.

> Flush Privileges;

Related article: http://jingyan.baidu.com/article/b907e627b0e3b846e7891cc9.html

2, after setting the connection error: 10038

The reason is that the server's port 3306 is not open.

Set up:

1. reading the wrong window first

650) this.width=650; "Src=" http://a.hiphotos.baidu.com/exp/w=480/sign=a3ec428d4836acaf59e097f44cd98d03/ 35a85edf8db1cb1321573da7de54564e92584b43.jpg "width=" 445 "height=" "alt=" 35a85edf8db1cb1321573da7de54564e92584b43 "/>

2 . First connect to the server remotely, click "Start"-"Administrative Tools"-"Windows Firewall with Advanced Security".

650) this.width=650; "Src=" http://c.hiphotos.baidu.com/exp/w=480/sign=c91084fac98065387beaa51ba7dda115/ 9c16fdfaaf51f3deee8cb8d097eef01f3a297943.jpg "width=" 480 "height=" 327 "alt=" 9c16fdfaaf51f3deee8cb8d097eef01f3a297943 "/>

3 . In the open window, select "Inbound Rules" on the left, and click "New rule" on the right to create a new inbound rule.

650) this.width=650; "Src=" http://g.hiphotos.baidu.com/exp/w=480/sign=463b67c7f8f2b211e42e8446fa806511/ 91ef76c6a7efce1bcb15c97eac51f3deb48f6543.jpg "width=" 480 "height=" 297 "alt=" 91ef76c6a7efce1bcb15c97eac51f3deb48f6543 "/>

4. Select "Port" in "rule type", then next

650) this.width=650; "Src=" http://c.hiphotos.baidu.com/exp/w=480/sign=c3a89eb05a82b2b7a79f38cc01accb0a/ F11f3a292df5e0fefbc98fb55f6034a85fdf72b4.jpg "width=" 480 "height=" 385 "alt=" F11f3a292df5e0fefbc98fb55f6034a85fdf72b4 "/>

5 . Select "Specific local Port", enter 3306, and then next.

650) this.width=650; "Src=" http://b.hiphotos.baidu.com/exp/w=480/sign=a203458d4836acaf59e097f44cd88d03/ 35a85edf8db1cb1320b83aa7de54564e93584bb4.jpg "width=" 480 "height=" 383 "alt=" 35a85edf8db1cb1320b83aa7de54564e93584bb4 "/>

6, Check "Allow connections" and then next.

 650) this.width=650; "Src=" http://f.hiphotos.baidu.com/exp/w=480/sign=433190487fd98d1076d40d39113eb807/ 48540923dd54564effb4e28db0de9c82d0584fb4.jpg "width=" 480 "height=" 381 "alt=" 48540923dd54564effb4e28db0de9c82d0584fb4 "/>

7, This step is selected by default, and then next

 650) this.width=650; "Src=" http://f.hiphotos.baidu.com/exp/w=480/sign=21e402552c2eb938ec6d7bfae56285fe/ Cdbf6c81800a19d8c93d85b130fa828ba61e4643.jpg "width=" 480 "height=" 381 "alt=" cdbf6c81800a19d8c93d85b130fa828ba61e4643 "/>

8, Finally enter the new inbound rule name, fill it out, and understand it.

650) this.width=650; "Src=" http://h.hiphotos.baidu.com/exp/w=480/sign=7432870b8f5494ee87220e111df4e0e1/ A686c9177f3e67094ed1434b38c79f3df9dc55b4.jpg "width=" 480 "height=" 383 "alt=" A686c9177f3e67094ed1434b38c79f3df9dc55b4 "/>

9. You can see the new inbound rules in the list of inbound rules when you're done.

650) this.width=650; "Src=" http://f.hiphotos.baidu.com/exp/w=480/sign=78169cd5f0deb48ffb69a0d6c01e3aef/ 94cad1c8a786c917fad2548dca3d70cf3ac757b4.jpg "width=" 480 "height=" 225 "alt=" 94cad1c8a786c917fad2548dca3d70cf3ac757b4 "/>

10.

Now, once again, when you connect to the MySQL remote database locally, you find that you have access to it properly.

Problem solving.


MySQL Remote connection settings

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.