mysql-1045(28000)错误
说明:win7系统,已经装过一个安装版的mysql(服务没有启动),然后又安装了一个免安装版的mysql,然后启动该免安装版的mysql后,用root用户无法登陆(因为想着root用户默认密码是空,但是却无法登陆),如下所示:
D:\>cd D:\MySQL Server 5.1\bin
D:\MySQL Server 5.1\bin>mysql -u root mysql
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
解决办法:
D:\MySQL Server 5.1\bin>mysql -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 9
Server version: 5.5.24 MySQL Community Server (GPL)
Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL v2 license
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
将密码重新设置(设为空)
mysql> set password for 'root'@localhost=password('');
Query OK, 0 rows affected (0.00 sec)
mysql> exit
Bye
再次以root用户(密码为空)则可以登陆:
D:\MySQL Server 5.1\bin>mysql -u root
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 10
Server version: 5.5.24 MySQL Community Server (GPL)
Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL v2 license
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
我想出现这个原因,估计是因为我之前装的这个mysql,root用户密码修改了,不是非空了。
mysql-1045(28000)错误的更多相关文章
- mysql学习笔记1---mysql ERROR 1045 (28000): 错误解决办法
mysql ERROR 1045 (28000): 错误解决办法 在启动mysql服务后,登陆mysql的窗口的时候,执行mysql命令,结果报错,没法登陆. (在安装mysql和配置的时候,我是 ...
- 关于mysql ERROR 1045 (28000)错误的解决办法
错误情景: 使用Navicat打开mysql的时候弹出错误框 错误代码: ERROR 1045 (28000): Access denied for user 'ODBC'@'localhost' ( ...
- mysql ERROR 1045 (28000): 错误解决办法
ERROR 1045 (28000): Access denied for user 'ODBC'@'localhost' (using password: NO) ERROR 1045 (28000 ...
- mysql登录时,ERROR 1045 (28000): 错误解决办法
错误问题的描述: ERROR 1045 (28000): Access denied for user 'ODBC'@'localhost' (using password: NO) ERROR 10 ...
- mysql 在登陆的时候出现error 1045 (28000): 错误解决办法
错误显示:ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES) 解决方案: 1.找到配 ...
- 1.mysql ERROR 1045 (28000): 错误解决办法
转自:https://www.cnblogs.com/jpwz/p/6061214.html ERROR 1045 (28000): Access denied for user 'ODBC'@'lo ...
- mysql学习笔记1---mysql ERROR 1045 (28000): 错误解决办法(续:深入分析)
在命令行输入mysql -u root –p,输入密码,或通过工具连接数据库时,经常出现下面的错误信息,详细该错误信息很多人在使用MySQL时都遇到过. ERROR 1045 (28000): Acc ...
- mysql开启skip-name-resolve 导致root@127.0.0.1(localhost)访问引发的ERROR 1045 (28000)错误解决方案
为什么配置skip-name-resolve? 由于mysql -h${ip} 远程访问速度过慢, mysql -uroot -p123456 根据网友经验(https://www.cnblogs.c ...
- mac下mysql 1045 (28000): Access denied for user 'root'@'localhost' (using password:
新入了mac pro,安装好mysql后,用终端进入mysql遇到个问题: 1045 (28000): Access denied for user 'root'@'localhost' (using ...
- 登录MySQL提示ERROR 1045 (28000)错误解决方法
今天,登录服务器准备修改数据库的一些东西.但输入密码,却进不了数据库并提示一个错误,如下图 再确认密码没错的情况下,还是进不了数据库.便在网上找到了解决方法,记录下来,供参考学习. 解决方法: 总体思 ...
随机推荐
- Persistent Netcat Backdoor
In this example, instead of looking up information on the remote system, we will be installing a net ...
- Win10远程桌面出现身份验证错误要求的函数不受支持
Win10更新了,远程连不上了,还是手动来修改,用户体验不好,差评! 解决方法: 在本地(而非远程机),运行 gpedit.msc,打开本地组策略:计算机配置>管理模板>系统>凭据分 ...
- android中RecyclerView控件实现点击事件
RecyclerView控件实现点击事件跟ListView控件不同,并没有提供类似setOnItemClickListener()这样的注册监听器方法,而是需要自己给子项具体的注册点击事件. 本文的例 ...
- ZH奶酪:PHP error_log()将错误信息写入日志文件
error_log() 是发送错误信息到某个地方的一个函数,在程序编程中比较常见,尤其是在程序调试阶段. bool error_log ( string $message [, int $messag ...
- 微信小程序 - 非入侵式布局
非入侵式布局,就是不影响原有内容以及代码,增加用户体验感(UE)的一种方式. 例如我们每个接口必须返回: 0:请求成功 -1:请求失败 .... 这样就便于前端判断数据是否加载成功,然后以客观的方式提 ...
- vSphere Replication:虚拟机的保护伞
http://server.zdnet.com.cn/server/2013/0401/2151318.shtml ZDNet至顶网服务器频道 04月01日 新闻消息: 保护IT环境的一个基本方面就是 ...
- TP - 001
- mysql主从备份功能配置与測试
在高訪问量服务环境下,单机配置mysql服务将无法满足频繁快速的数据读写操作. 一旦mysql出现故障造成数据丢失.无法恢复. 因此.在mysql服务上启用主从备份功能,支持读写分离技术.最靠可的是搭 ...
- 【Zookeeper】源码分析之请求处理链(三)之SyncRequestProcessor
一.前言 在分析了PrepRequestProcessor处理器后,接着来分析SyncRequestProcessor,该处理器将请求存入磁盘,其将请求批量的存入磁盘以提高效率,请求在写入磁盘之前是不 ...
- Spring解决Hibernate中的懒加载问题
OpenSessionInViewFilter 过滤器将 Hibernate Session 绑定到请求线程中,它将自动被 Spring 的事务管理器探测到. <filter> ...