紧急求助!mysql登录的权限问题
我在数据库中设置了一个ps用户,并赋予他在任何机器上登陆的权限,下面是user表中的信息:| Host | User | Password | Select_priv | Insert_priv | Update_priv | Delete_priv |
| % | ps | 565491d704013245 | Y | Y | Y | Y | Y |
可奇怪的是在别的机器上用ps可以顺利登陆,可在本机上登陆反而出现一下错误:
ERROR 1045 (28000): Access denied for user 'ps'@'localhost' (using password: YES)
我装的mysql是4.1.7版本的,请问这是什么原因啊,怎样修改呢?
我写的mysql命令是:grant all privileges on *.*tops identified by "ok";
当然最后还用了flush privileges;命令。 写出你的代码看看 :?: 是不是 ps 帐号的设置有问题?
Re: 紧急求助!mysql登录的权限问题
ERROR 1045 (28000): Access denied for user 'ps'@'localhost' (using password: YES)是不是ps的密码有问题呢?建议安装phpmyadmin管理MySQL更方便 :mrgreen: 是不是你的主机使用的有问题?
下面是我想的一个例子是这样的吗?
$ mysql -h localhost -u www -p
Enter password:
ERROR 1045: Access denied for user: 'www@localhost' (Using password: YES)
==============================================================
$ mysql -h localhost.localdomain -u www -p
Enter password:
Welcome to the MySQL monitor.Commands end with ; or \g.
Your MySQL connection id is 7 to server version: 3.23.58
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>
==============================================================
$ mysql -h fc3ise(我的主机名) -u www -p
Enter password:
Welcome to the MySQL monitor.Commands end with ; or \g.
Your MySQL connection id is 3 to server version: 3.23.58
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> \q
Bye
不是帖出你的来先!! 我遇到了楼上的兄弟的问题,怎么解决。 我曾几模糊的记忆里有这么一个概念:
如果远程出现这样的情况,一般是由于缺少一个设置,具体的命令我忘了,不好意思,白说了
不过这个解决方法还是有的,我以前练习过,希望有兄弟可以想起来 我的情况是用root登陆不了,用其他任何拥护名不用密码都可以登陆,
修改密码时:
/usr/bin/mysqladmin: unable to change password; error: 'Access denied for user:
'@localhost' to database 'mysql''
是怎么回事呀?? 请注意user表中的Host字段的值以及其相对应的User qiao!
my mysql had the same problem this morning
so i add a new user
its `Host` is localhost
| Host | User | Password | Select_priv | Insert_priv | Update_priv | Delete_priv |
| % | ps | 565491d704013245 | Y | Y | Y | Y | Y |
| localhost | ps | 565491d704013245 | Y | Y | Y | Y | Y |
now you can login @localhost
sorry my fcitx is broken
页:
[1]