SELECT command denied to user 'username'@'ip' for table 'user'错误处理
错误信息
<div class="code-tools">
<i class="theme-switch-btn"></i><i class="copy-btn"></i>
</div>
<pre class="pre codeblock" id="codeblock-op1-mla-6o9"><code class="hljs pgsql"><span class="hljs-keyword">SELECT</span> command denied <span class="hljs-keyword">to</span> <span class="hljs-keyword">user</span> <span class="hljs-string">'username'</span>@<span class="hljs-string">'ip'</span> <span class="hljs-keyword">for</span> <span class="hljs-keyword">table</span> <span class="hljs-string">'user'</span> </code></pre>
<div class="pre-scrollbar-track" style="display: none;width: 100%;height: 4px;margin-bottom: 16px;">
<div class="pre-scrollbar-thumb" style="height: 100%;background-color: #d7d8d9;position: relative;"></div>
</div>
</div>
排查步骤
- 测试RDS实例是否异常。可以使用mysql客户端连接到RDS,查询对应的表,如果可以正常查询,说明RDS没有问题。
- 用Wireshark软件抓包本机发出的实际请求:
- 在Wireshark界面中,选择捕获 > 选项,在输入页签选择连接RDS的内网网卡,在输出页签填写输出的文件名,然后单击开始。

- 复现问题,问题复现后,停止抓包。
- 在Wireshark界面中,选择捕获 > 选项,在输入页签选择连接RDS的内网网卡,在输出页签填写输出的文件名,然后单击开始。
- 打开生成的抓包文件,在显示过滤器里输入mysql,过滤出mysql协议,找到报错的包。

- 在报错的条目上单击右键,选择追踪流 > TCP流。

- 检查发送的SQL是否正确。
说明 上面的案例中,报错原因在于库名是fnb,而程序拼接出来的是hnb.user,数据库名拼接错误导致报错, 修正数据库名后问题解决。
SELECT command denied to user 'username'@'ip' for table 'user'错误处理的更多相关文章
- MySQL:select command denied to user for table 'proc'案例
使用EMS MySQL Manager Pro(3.4.0.1)连接MySQL 5.6.20时,报错:"SELECT command denied to user xxx@xxx.xxx.x ...
- mysqldump: Got error: 1142: SELECT, LOCK TABLES command denied to user 'root'@'localhost' for table 'accounts' when using LOCK TABLES
AutoMySQLBackup备份时,出现mysqldump: Got error: 1142: SELECT, LOCK TABLES command denied to user 'root'@' ...
- ERROR 1044 (42000) ERROR 1142 (42000): SELECT command denied to user ''@'localhost' for table 'user'
ERROR: Access denied for user 'root'@'localhost' (using password: NO) 发现: mysql -u root@localh ...
- [phpmyadmin] phpmyadmin select command denied to user
phpmyadmin 在查看一个数据库中Table的数据的时候,会提示 select command denied to user 在Ubuntu下,我是使用重装Phpmyadmin的方式解决的 卸载 ...
- com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: SELECT command denied to user’
Linux环境 Mysql+Hibernate command denied to user 错误 错误信息 如下: com.mysql.jdbc.exceptions.jdbc4.MySQLSynt ...
- com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: SELECT command denied to user 'xxxx'@''
这两天项目一直在报这个错误消息: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: SELECT command denied to ...
- [已解决]#1142 - SELECT command denied to user ''@'localhost' for table 'pma_table_uiprefs'
症状:在phpmyadmin那边打不开表,提示 #1142 - SELECT command denied to user ''@'localhost' for table 'pma_table_ui ...
- SELECT command denied to user ''@'%' for column 'xxx_id' in table 'users_xxx' 权限问题
问题的原因是:最主要是权限的问题. 大概说下 ,我导数据库时提示错误:SELECT command denied to user ''@'%' for column 'xxx_id' in table ...
- Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: REFERENCES command denied to user 'nali'@'localhost' for table 'dbs'
按照教程 Install hive on Mac with Homebrew,在 mac 上安装 Hive 时, 最后执行 hive 命令后,出现错误: Exception in thread &qu ...
随机推荐
- Pod在多可用区worker节点上的高可用部署
一. 需求分析 当前kubernetes集群中的worker节点可以支持添加多可用区中的ECS,这种部署方式的目的是可以让一个应用的多个pod(至少两个)能够分布在不同的可用区,起码不能分布在同一个可 ...
- Mysql主从安装配置
Mysql主从安装配置 环境: 主从服务器上的MySQL数据库版本同为5.1.34 主机IP:192.168.0.1 从机IP:192.168.0.2 一. MySQL主服务器配置 1.编辑配置 ...
- idea 项目热部署设置
1.引入pom.xml() <!-- 热部署(必须) --> <dependency> <groupId>org.springframework.boot</ ...
- concurrent模块
concurrent包 concurrent.futrues模块 3.2版本引入 异步并行任务模块,提供一个高级的异步可执行的便利接口. 提供了两个池执行器 ThreadPoolExecutor异步调 ...
- Directx教程(28) 简单的光照模型(7)
原文:Directx教程(28) 简单的光照模型(7) 现实生活中的点光源都是随着距离衰减的,比如一个电灯泡在近处会照的很亮,远处光线就很弱.本节中我们在前面光公式的基础上,再给漫反射和 ...
- [CS]C#操作word 2016-04-17 18:30 1506人阅读 评论(35) 收藏
最近在做的项目已经改了好几版,最近这一版用到了word,当然不是直接使用word,而是使用第三方的ActiveX控件:dsoframer.ocx,此控件的使用和其他控件的使用流程没有任何区别,接下来介 ...
- vue-quill-editor 封装成组件;图片文件流上传;同一页面多个编辑器样式异常解决办法
使用方法: 引入并注册组件,然后直接使用: @getcode是同步获取编辑器内容的::contentDefault是编辑器的默认内容: 注意:如果同一个页面多个编辑器,参数id不能相同,否则只有第一个 ...
- 设置select和option的文字居中
select{ width: auto; padding: 0 1%; //左右一定要设置 margin: 0; } option{ text-align:center; }
- oracle函数 DUMP(w[,x[,y[,z]]])
[功能]返回数据类型.字节长度和在内部的存储位置. [参数] w为各种类型的字符串(如字符型.数值型.日期型……) x为返回位置用什么方式表达,可为:8,10,16或17,分别表示:8/10/16进制 ...
- tensorflow 卷积层
TensorFlow 卷积层 让我们看下如何在 TensorFlow 里面实现 CNN. TensorFlow 提供了 tf.nn.conv2d() 和 tf.nn.bias_add() 函数来创 ...