问题一:can’t connect to mysql server on ‘192.168.xxx.xxx’(10061)
解决:
sudo vim /etc/mysql/mysql.conf.d/mysqld.cnf,bind-address绑定了登陆的IP,把这两行代码注释掉,然后重启mysql。
问题二:1130-host ‘’ is not allowde to connect to this mysql server
在Linux中登录到mysql中
use mysql;
select host,user,plugin,authentication_string from mysql.user;

修改user表中的Host
update user set Host=’%’ where User=‘root’;
flush privileges;
连接成功。



![洛谷 P1011 [NOIP1998 提高组] 车站](https://img-blog.csdnimg.cn/direct/7962cd494f324ddeac94b4ee3aaad2c4.png)











![[ C++ ] 深入理解模板( 进 阶 )](https://img-blog.csdnimg.cn/direct/2c60db7f2c1d40db9c6398eb2f3b8fad.png)



