解决报错:错误1130- Host xxx is not allowed to connect to this MariaDb server
来源:互联网 发布:网游数据提取 编辑:程序博客网 时间:2024/05/19 23:13
在云服务器上面搭建了MariaDb(MariaDB是MySQL源代码的一个分支),但是远程链接不上。
首先,你要确保服务器安全组3306端口已经开放。
在确保端口开放的情况下,如果出现错误代码1130- Host xxx is not allowed to connect to this MariaDb server,说明是权限问题。如图:
有两种解决方法:
1.授权法
GRANT ALL PRIVILEGES ON *.* TO 'user'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION; // %:表示从任何主机连接到mysql服务器
FLUSH PRIVILEGES;
或者
GRANT ALL PRIVILEGES ON *.* TO 'user'@'116.30.70.187' IDENTIFIED BY 'password' WITH GRANT OPTION;//表示从指定ip从任何主机连接到mysql服务器
FLUSH PRIVILEGES;
2.该表法
可能是你的帐号不允许从远程登陆,只能在localhost。这个时候只要在localhost的那台电脑,登入MySQL后,更改 "mysql" 数据库里的 "user" 表里的 "host" 项,从"localhost"改称"%"
mysql -u root -p
mysql>use mysql;
mysql>update user set host = '%' where user = 'root' and host='localhost';
mysql>select host, user from user;
然后重启MySQL服务。或再执行 执行一个语句 mysql>FLUSH RIVILEGES 使修改生效。
这样就大功告成,就可以远程链接数据库了
- 解决报错:错误1130- Host xxx is not allowed to connect to this MariaDb server
- host XXX is not allowed to connect to this MariaDB
- 服务器连接错误Host 'XXX' is not allowed to connect to this MySQL server如何解决
- 解决服务器连接错误Host ‘XXX’ is not allowed to connect to this MySQL server
- 解决服务器连接错误Host ‘XXX’ is not allowed to connect to this MySQL server
- 解决服务器连接错误Host ‘XXX’ is not allowed to connect to this MySQL server
- 解决服务器连接错误Host ‘XXX’ is not allowed to connect to this MySQL server
- 解决服务器连接错误Host ‘XXX’ is not allowed to connect to this MySQL server
- 解决Navicat 报错:1130-host ... is not allowed to connect to this MySql server
- 解决Navicat 报错:1130-host ... is not allowed to connect to this MySql server,MySQL
- 解决Navicat 报错:1130-host ... is not allowed to connect to this MySql server,MySQL
- Host '*' is not allowed to connect to this MariaDB server
- Host '*' is not allowed to connect to this MariaDB server
- 解决MySQL ERROR 1130 (HY000): Host 'XXX' is not allowed to connect to this MySQL server
- 解决:MYSQL远程连接错误码:1130 Host 'xxx' is not allowed to connect to this MySQL server
- 主机连接虚拟机MySQL报错:Host 'xxx.xxx.xxx.xxx' is not allowed to connect to this MySQL server
- 怎么解决mysql不允许远程连接的错误1130 - Host'xxx.xxx.xxx.xxx' is not allowed to connect to this MySQL server“
- message from server: "Host 'xxx' is not allowed to connect to this MySQL server的解决
- javaScript学习-动态为ul添加li
- wince整体解决方案编译错误的解决办法(StdAfx.obj' not allowed with multiple source files )
- Android数据加密之Aes加密
- Android7.0 PowerManagerService(4) Power按键流程
- 第三节:SpringBoot使用properties配置文件实现多环境配置
- 解决报错:错误1130- Host xxx is not allowed to connect to this MariaDb server
- Java基础之四大内部类(结合代码理解)
- MVC框架
- Maven下安装oracle详细步骤
- Windows 2008 R2 DFS分布式文件系统配置
- 复习Java(五)猜测随机生成的数字Program
- Linux服务器上配置多个Tomcat
- ExtJS Grid Tooltip提示 鼠标悬停
- Hadoop学习之MapRduce笔记