MySQL错误#1133-在用户表中找不到任何匹配的行 [英] MySQL Error #1133 - Can't find any matching row in the user table

查看:389
本文介绍了MySQL错误#1133-在用户表中找不到任何匹配的行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

无法使用 5.5.27-MySQL 3.5.2.2-phpMyAdmin 为用户设置密码.当尝试以用户身份登录phpMyAdmin时设置密码时,会弹出以下错误:

Unable to set password for a user using 3.5.2.2 - phpMyAdmin for 5.5.27 - MySQL. When trying to set the password while logged onto phpMyAdmin as the user, it pops up the following error:

#1133 - Can't find any matching row in the user table

以root用户身份登录后,会弹出以下密码设置成功消息.

When logged on as root, following password set successfully message pops up.

SET PASSWORD FOR 'user'@'%' = PASSWORD( '***' )

在任何一种情况下,密码都不会设置并且保持不变,空白.

In either case, password does not set and stays as it currently is, blank.

推荐答案

事实证明,错误确实非常模糊!

It turns out, the error is very vague indeed!

1)以root身份登录时正在设置密码,因为它正在更新MySql下users表中的user/password字段.

1) Password was setting while logged on as root, as it was updating the user/password field in the users table under MySql.

2)当以用户身份登录时,密码实际上并没有改变,即使在MySql的users表中指定了一个密码,config.inc.php文件也允许不使用密码进行身份验证.

2) When logged on as user, password was in fact not changing and even though there was one specified in the users table in MySql, config.inc.php file allowed authentication without password.

解决方案:

以下值更改为 config.inc.php 中的 false .

Change following value to false in the config.inc.php.

$cfg['Servers'][$i]['AllowNoPassword'] = true;

以使其读取

$cfg['Servers'][$i]['AllowNoPassword'] = false;

用户的主机 Any % 更改为 localhost 在MySql用户表中.这可以通过 phpMyAdmin 控制台轻松实现.

Change user's host from Any or % to localhost in MySql users table. This could easily be achieved via phpMyAdmin console.

这两个更改使我可以使用其密码进行用户身份验证,并且不允许不使用密码进行身份验证.

These two changes allowed me to authenticate as user with it's password and disallowed authentication without password.

它还允许用户在以用户身份登录时更改其密码.

It also allowed user to change its password while logged on as user.

似乎所有的权限,其余的都通过这两个更改得到了修复.

Seems all permissions and the rest was fixed with these two changes.

这篇关于MySQL错误#1133-在用户表中找不到任何匹配的行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆