不允许1130连接mysql_ERROR 1130(HY000):主机”不允许连接到此MySQL...

参见英文答案 > Host ‘xxx.xx.xxx.xxx’ is not allowed to connect to this MySQL server????????????????????????????????????24个

为什么哦为什么我不能连接到mysql?

mysql -u root -ptest101 -h xxx.xxx.xxx.xxx

ERROR 1130 (HY000): Host 'xxx.xxx.xxx.xxx' is not allowed to connect to this MySQL server

在my.cnf我有以下内容

# Instead of skip-networking the default is now to listen only on

# localhost which is more compatible and is not less secure.

bind-address = 0.0.0.0

我也跑了以下……

'UPDATE mysql.user SET Password = PASSWORD('test101') WHERE User = 'root';

FLUSH PRIVILEGES;

我可以使用mysql -u root -ptest101在主机上访问但不能使用mysql -u root -ptest101 -h xxx.xxx.xxx.xxx

哇…为什么会这样?我是ubuntj 12.04

mysql> SELECT host FROM mysql.user WHERE User = 'root';

+---------------------------------------------+

| host |

+---------------------------------------------+

| % |

| 127.0.0.1 |

| ::1 | |

| localhost |

+---------------------------------------------+

5 rows in set (0.00 sec)

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值