连接mysql时报:message from server: "Host '192.168.76.89' is not allowed to connect to this MySQL server 处理方案
1、先用localhost方式连接到MySQL数据库,然后使用MySQL自带的数据库mysql;
use mysql;
2、执行:select host from user where user = 'root'; 发现,host的值就是localhost。
所以将它的值改掉:update user set host='%' where user = 'root';
3、修改完成后,执行:flush privileges;
将修改内容生效,再次配置时,用IP地址或者localhost 就都能正常连接到MySQL数据库了。
操作如下:
mysql> use mysql
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> select host from user where user = 'root';
+-----------+
| host |
+-----------+
| localhost |
+-----------+
1 row in set (0.00 sec)
mysql> update user set host='%' where user = 'root';
Query OK, 1 row affected (0.00 sec)
Rows matched: 1 Changed: 1 Warnings: 0
mysql> select host from user where user = 'root';
+------+
| host |
+------+
| % |
+------+
1 row in set (0.00 sec)
mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)
mysql>
连接mysql时报:message from server: "Host '192.168.76.89' is not allowed to connect to this MySQL server 处理方案的更多相关文章
- 连接mysql时报:message from server: "Host '192.168.76.89' is not allowed to connect to this MySQL server
处理方案: 1.先用localhost方式连接到MySQL数据库,然后使用MySQL自带的数据库mysql; use mysql: 2.执行:select host from user where u ...
- java.sql.SQLException: null, message from server: "Host '192.168.xxx.xxx' is not allowed to connect to this MySQL server"
当你连接自己的电脑上的MySQL时,报这样的错,你可以把ip换成 127.0.0.1或者localhost ,当然前提是用户名和密码正确
- java.sql.SQLException: null, message from server: "Host '192.168.126.100' is not allowed to connect to this MySQL server"
- hive报错java.sql.SQLException: null, message from server: "Host '192.168.126.100' is not allowed to connect to this MySQL server"
- 报错 "Host '192.168.209.1' is not allowed to connect to this MySQL server"
版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明.本文链接:https://blog.csdn.net/weixin_37632381/artic ...
- 通过navicat连接mysql服务器提示SQL Error (1130): Host '192.168.1.100' is not allowed to connect to this MySQL server
新装一个mysql,尝试用通过navicat连接mysql服务器的时候提示: SQL Error (1130): Host '192.168.1.100' is not allowed to conn ...
- SQL Error (1130): Host '192.168.1.126' is not allowed to connect to this MySQL server
通过HeidiSQL连接MYSQL数据库报错: SQL Error (1130): Host '192.168.1.126' is not allowed to connect to this MyS ...
- ERROR 1130 (HY000): Host '192.168.20.165' is not allowed to connect to this MySQL server
问题 远程连接mysql时遇到如下问题: ERROR 1130 (HY000): Host '192.168.20.165' is not allowed to connect to this MyS ...
- Mysql远程连接报错:SQL Error (1130): Host '192.168.61.128' is not allowed to connect to this MySQL server
Mysql远程连接报错:SQL Error (1130): Host '192.168.0.18' is not allowed to connect to this MySQL server ...
随机推荐
- 好久没更了,确实太忙了--dedecms篇
最近写了一个地方新闻网站,可以看看:www.qiluhuabao.com.模仿www.bashan.com写的 用的是dedecms,只听过,没用过.终于在上周来了一个必须用到cms的项目,现学现卖, ...
- EntityFramework 学习 一 DBEntityEntry
DbEntityEntry是一个重要的类,用来获取各种各样的实体信息 可以通过DBContext的Entry方法获取DbEntityEntry的实例 DBEntityEntry studentEntr ...
- RSA加密方法java工具类
package com.qianmi.weidian.common.util; import java.io.ByteArrayOutputStream; import java.security.K ...
- 属性 visibility
http://www.w3school.com.cn/cssref/pr_class_visibility.asp 可能的值 值 描述 visible 默认值.元素是可见的. hidden 元素是不可 ...
- 分享知识-快乐自己:mongodb 安装部署(linux)
1):下载 mongodb 包 [root@admin tools]# wget http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-3.0.6. ...
- C++(二)— STL容器的基本用法
1.vector基本操作 关于vector简单的讲就是一个动态增长的数组,里面有一个指针指向一片连续的内存空间,当空间装不下的时候会自动申请一片更大的空间(空间配置器)将原来的数据拷贝到新的空间,然后 ...
- Oracle学习笔记_02_基本SQL
1.select语句 (1)语法 SELECT *|{[DISTINCT] column|expression [alias],...} FROM table; (2)示例: 选择全部列 SELECT ...
- 【遍历二叉树】02二叉树的中序遍历【Binary Tree Inorder Traversal】
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 给定一个二叉树,返回他的中序遍历的 ...
- C++ STL, next_permutation用法。
next_permutation 将按字母表顺序生成给定序列的下一个较大的序列,直到整个序列为 #include"iostream" #include"algorithm ...
- bzoj 1242 弦图判定 MCS
题目大意: 给定一张无向图,判断是不是弦图. 题解: 今天刚学了<弦图与区间图> 本来写了一个60行+的学习笔记 结果因为忘了保存重启电脑后被还原了... 那就算了吧. MCS最大势算法, ...