ERROR 1045 (28000): Access denied for user 'root'@'SR3' (using password: YES)
2013-11-14 13:28
393 查看
解决方案:
[mysql@SR3 ~]$ mysql -h 10.86.87.155 -uroot -pinfohow
ERROR 1045 (28000): Access denied for user
'root'@'SR3' (using password: YES)
[mysql@SR3 ~]$ mysql -hlocalhost -uroot -pinfohow
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.5.16-log Source distribution
Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> update user set password=PASSWORD("infohow") where user="root";
ERROR 1046 (3D000): No database selected
mysql> use mysql;
Database changed
mysql> update user set password=PASSWORD("infohow") where user="root";
Query OK, 3 rows affected (0.03 sec)
Rows matched: 4 Changed: 3 Warnings: 0
mysql> commit;
Query OK, 0 rows affected (0.00 sec)
mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)
mysql> exit
Bye
[mysql@SR3 ~]$ mysql -h 10.86.87.155 -uroot -pinfohow
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 4
Server version: 5.5.16-log Source distribution
Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> exit
[mysql@SR3 ~]$ mysql -h 10.86.87.155 -uroot -pinfohow
ERROR 1045 (28000): Access denied for user
'root'@'SR3' (using password: YES)
[mysql@SR3 ~]$ mysql -hlocalhost -uroot -pinfohow
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.5.16-log Source distribution
Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> update user set password=PASSWORD("infohow") where user="root";
ERROR 1046 (3D000): No database selected
mysql> use mysql;
Database changed
mysql> update user set password=PASSWORD("infohow") where user="root";
Query OK, 3 rows affected (0.03 sec)
Rows matched: 4 Changed: 3 Warnings: 0
mysql> commit;
Query OK, 0 rows affected (0.00 sec)
mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)
mysql> exit
Bye
[mysql@SR3 ~]$ mysql -h 10.86.87.155 -uroot -pinfohow
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 4
Server version: 5.5.16-log Source distribution
Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> exit
相关文章推荐
- XML之TinyXML推荐RapidXML
- Android中滑屏实现----手把手教你如何实现触摸滑屏以及Scroller类详解
- js本地存储解决方案(localStorage与userData)
- #pragma 编译器自定义参数
- Python路径
- 回调函数的介绍
- Tomcat6.0源码学习--Connector架构
- #pragma
- Android绘图基础
- 南师大2006年GIS考研真题
- keepalived实现双主模式高可用集群
- 1032. Sharing (25)
- 解决android Device无法debug
- VC++内存释放总结
- Hibernate的generator属性之意义
- 强制浏览器下载PDF文件
- mysql与memcache结合
- ARM处理器的程序与数据存储(冯·诺依曼与哈佛结构)
- 关于 Java 常用工具您不知道的 5 件事
- java反射机制