Access denied for user 'root'@'localhost' (using password: YES) (可以正确解决)
来源:互联网 发布:速卖通seo 编辑:程序博客网 时间:2024/06/06 01:15
本文为大家讲解的是mysql错误:Access denied for user 'root'@'localhost' (using password: YES)解决方法,感兴趣的同学参考下.
注意: 加红色的地方是重点
错误描述
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
解决方案
windows环境
编辑mysql配置文件my.ini(不知道在哪请搜索),在[mysqld]这个条目下加入 skip-grant-tables
保存退出后重启mysql
1.点击“开始”->“运行”(快捷键Win+R)。
2.启动:输入 net stop mysql
3.停止:输入 net start mysql
cmd mysql -u root -p 回车
如果在cmd下报mysql不是可执行命令,则说明你的mysql没有加到环境变量里,请自动cd到mysql安装目录的bin目录下再执行mysql -u root -p 回车
1.进入mysql数据库:
mysql> use mysql;
2.给root用户设置新密码:
mysql> update user set password=password("新密码") where user="root";
3.刷新数据库
mysql> flush privileges;
4.退出mysql:
mysql> quit
修改一下my.ini这个文件,把我们刚才加入的"skip-grant-tables"这行删除,保存退出再重启mysql就可以了
0 0
- Access denied for user 'root'@'localhost' (using password: YES) (可以正确解决)
- 解决'Access denied for user 'root'@'localhost' (using password: YES)'
- #1045 - Access denied for user 'root'@'localhost' (using password: YES)
- Access denied for user 'root'@'localhost' (using password: YES) 问题解决
- access denied for user 'root'@'localhost' using password yes
- access denied for user 'root'@'localhost' using password yes
- 1045 access denied for user 'root'@'localhost' using password yes
- Access denied for user 'root'@'localhost' (using password: YES)解决办法
- Access denied for user: 'root@localhost' (Using password: YES)
- Access denied for user 'root'@'localhost' (using password: YES)
- Access denied for user 'root'@'localhost' (using password:YES) 解决方案
- mysql Access denied for user 'root'@'localhost' (using password: YES)
- Access denied for user 'root'@'localhost' (using password: YES)
- Access denied for user 'root'@'localhost' (using password:YES)
- #1045 - Access denied for user 'root'@'localhost' (using password: YES)
- Access denied for user 'root'@'localhost' (using password: YES)
- mysql Access denied for user 'root'@'localhost' (using password: YES)
- Access denied for user 'root'@'localhost' (using password: YES)
- Altium Designer 覆铜时过孔连接形式的设置——只将过孔连接设置为 Direct Connect
- Java 多线程实现接口Runnable和继承Thread区别
- 细说 Form (表单)
- 文本分类参考文章
- windows下捕获dump
- Access denied for user 'root'@'localhost' (using password: YES) (可以正确解决)
- iOS socket使用技巧
- openwrt 进编译之前的准备
- java基本数据类型对象包装类总结
- 单例 xml
- SQL连接查询总结和练习
- 信息资源管理总结
- Boost.Asio技术文档
- VS2005 release 模式下提示缺少MFC80U.dll.