本地登录1045需要修改密码的看:
https://www.cnblogs.com/wangbaobao/p/7087032.html
ERROR 1130 (HY000): Host '172.17.0.1' is not allowed to connect to this MySQL server
use mysql;
update user set host='%' where user='root';
flush privileges
ERROR 2003 (HY000): Can't connect to MySQL server on '139.196.114.29' (60)
https://blog.csdn.net/rufanchen_/article/details/8538189
阿里云服务器需要在实例安全组新增配置
https://jingyan.baidu.com/article/03b2f78c31bdea5ea237ae88.html
需要开启防火墙时,可以设置开放端口
https://www.cnblogs.com/yuezc/p/13468704.html
原因:各种查找,说是其他ip地址没有访问这个库的权限,
解决办法:
进行授权
1.如果想root用户使用password从任何主机连接到mysql服务器的话。
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '**password**' WITH GRANT OPTION;
2.如果想用户root从ip为192.168.183.13的主机连接到mysql服务器,并使用password作为密码
GRANT ALL PRIVILEGES ON *.* TO 'root'@'**你的ip地址**' IDENTIFIED BY '**password**' WITH GRANT OPTION;
红色加粗部分根据自己的填
刷新权限: flush privileges;
然后再登录就OK了