别人需要连接自己数据库的时候需要对其开发远程连接。

1、进入MySQL

MySQL允许远程控制

2、使用mysql库执行use mysql;

MySQL允许远程控制

3、查询表中 执行:select user,password,host from user;

MySQL允许远程控制

4、执行:grant all privileges on *.* to root@"xxx.xxx.xxx.xxx" identified by "密码";

xxx.xxx.xxx.xxx :表示为允许访问的主机ip;密码:表示本数据库的连接密码

5、执行之后再次查询:select user,password,host from user;

 

相关文章:

  • 2021-12-19
  • 2021-12-19
  • 2021-11-26
  • 2022-01-27
  • 2021-05-23
  • 2022-12-23
  • 2021-12-04
猜你喜欢
  • 2021-11-02
  • 2022-01-07
  • 2021-09-07
  • 2021-12-18
  • 2021-12-18
  • 2021-12-18
相关资源
相似解决方案