当前位置:网站首页>MySQL——远程连接非本地MySQL数据库服务器,报错ERROR 1130: Host 192.168.3.100 is not allowed to connect to this MySQL s
MySQL——远程连接非本地MySQL数据库服务器,报错ERROR 1130: Host 192.168.3.100 is not allowed to connect to this MySQL s
2022-04-21 18:02:00 【叶不修233】
MySQL——远程连接非本地MySQL数据库服务器,报错ERROR 1130: Host 192.168.3.100 is not allowed to connect to this MySQL server的解决方案
前提条件,:要先确认被访问的电脑防火墙关闭:
控制面板-系统与安全-Windows Defender 防火墙-关闭-确定

一、问题
连接非本地数据库时,输入对方ip、账号和密码后点击连接测试,报错如图所示:

二、解决方案
1.在本地先被连接的登录数据库

2.使用show databases;命令查看被连接的数据库列表,发现有个名叫mysqlr的表:

3.使用use mysql;命令,使用mysql数据库

4.使用show tables;命令,查看发现里面有张叫做user的表

5.使用select host from user where user = ‘root’;命令,查看用户root在表中的host字段值(查看结果为localhost)
使用update user set host = ‘%’ where user = ‘root’;命令,把这个值改成‘%’
改完之后再次查询发现更改成功

6.使用flush privileges;命令刷新系统权限

7.退出窗口,再次连接,就连接成功了。
版权声明
本文为[叶不修233]所创,转载请带上原文链接,感谢
https://blog.csdn.net/weixin_56039103/article/details/124326287
边栏推荐
- 一个通用的CommonDialog
- 【论文精读】Stable Linear Structures and Seam Measurements for Parallax Image Stitching
- 看看技术宅怎么拯救学霸机,我用10块钱修好了笔记本电脑
- MATLAB中的图形绘制
- 怎么获取map值才不那么low,获取map参数的三种方式
- 信息系统项目管理师专有名词英文缩写&常见词汇
- Logstash ~ how logstash works
- 终于完成学生时代的梦想-制作掌机用单片机STM32手把手教你
- Finally someone made it clear! It turns out that this is the global one-piece network technology with low delay
- Finally complete the dream of student age - make a handheld machine and teach you with single chip microcomputer STM32
猜你喜欢

上位机这样玩,才有意思!

Part time jobs are higher than wages. In 2022, there are three sidelines with a monthly income of more than 10000

兼职比工资还高,2022年,月入过万的3个副业

不同研发协作模式在云效中的应用

Linux~libc.so.6(GLIBC_2.28)(64bit) 被 redis-5.0.3-1.nfs.x86_64 需要

Laxcus distributed operation redundancy and fault tolerance node

搭建JMeter+Jenkins+Ant持续化

Addition, deletion, modification and query of MySQL advanced table

有人声称「解决了」MNIST与CIFAR 10,实现了100%准确率

Shallow comparison between oceanbase and tidb - implementation plan
随机推荐
Logstash ~ input of logstash (input)
关于无线DOS攻击的常用方法简述
Beijing quasi GPS Beidou satellite timing system helps South Asia electronic production management system
How to get the map value is not so low. There are three ways to get the map parameters
Is Guotai Junan safe? It's reliable
京准GPS北斗卫星校时系统助力南亚电子生产管理系统
Variable ‘err‘ is accessed from within inner class, needs to be final or effectively final
Graphic drawing in MATLAB
LAXCUS分布式操作冗余容错之节点篇
单片机能做什么,你有什么有单片机或开源硬件做的有意思的作品吗
终于完成学生时代的梦想-制作掌机用单片机STM32手把手教你
Appreciation of single chip microcomputer DIY works, beginners come in to worship
Mp40n120-asemi FET
看完这篇教程,你将拥有自己的一个卫星(diy全程详解)
Dynamic programming: coin topic summary
有奖征文 | 重奖5000元,邀您投稿
看看项目经理是如何把一个项目带崩的
LogStash~LogStash命令行可选参数
国泰君安安全吗?靠谱嘛
2022超星学习通:媒体创意经济、走进东盟、职业生涯提升、音乐鉴赏、突发事件及自救