Configure mysql under windows to allow remote access


Tip: The following is the content of this article, the following cases are for reference

1.windows 10 allows mysql to be accessed remotely

1.1 windows10 open ports

Open the Control Panel -> System and Security -> Firewall -> Advanced Settings -> Entry Rules -> New Rule:

Insert picture description here
Insert picture description here
Insert picture description here
Insert picture description here
Insert picture description here
Insert picture description here

1.2 mysql database is enabled to allow root access to the local

#应用mysql数据库
use mysql;
#将root用户可访问改成所有
update user set host = '%' where user = 'root';
#刷新权限,使配置起作用
flush privileges;
#查看是否成功
select host, user from user;

Insert picture description here

1.3 Remote root can access windows local database

to sum up

Tip: I haven't finished writing yet, I have the opportunity to update the Linux system to enable remote access:

Guess you like

Origin blog.csdn.net/weixin_42096620/article/details/110798766
Recommended