Linux mysql 5.6: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
来源:互联网 发布:什么叫绿鞋机制知乎 编辑:程序博客网 时间:2024/06/02 19:43
转自VC错误:http://www.vcerror.com/?p=1643
问题描述:
解决方法:
具体的解决方法参考文章:http://www.vcerror.com/?p=1640
问题描述:
操作系统 :Red Hat Enterprise Linux Server release 5.7 (Tikanga) 64 bit
数据库版本 : Mysql 5.6.19 64 bit
安装了Mysql 5.6.19 64bit 版本的数据库,安装成功了,但是使用root登录时遇到了ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)错误. 如下所示
[root@DB-Server tmp]# rpm -ivh MySQL-server-5.6.19-1.rhel5.x86_64.rpm
Preparing... ########################################### [100%]
1:MySQL-server ########################################### [100%]
[root@DB-Server tmp]# rmp -ivh MySQL-client-5.6.19-1.rhel5.x86_64.rpm
-bash: rmp: command not found
[root@DB-Server tmp]# rpm -ivh MySQL-client-5.6.19-1.rhel5.x86_64.rpm
Preparing... ########################################### [100%]
1:MySQL-client ########################################### [100%]
[root@DB-Server tmp]# /etc/rc.d/init.d/mysql status
MySQL is not running[FAILED]
[root@DB-Server tmp]# /etc/rc.d/init.d/mysql start
Starting MySQL.[ OK ]
[root@DB-Server tmp]# mysql -u root -p
Enter password:
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
[root@DB-Server tmp]# mysql -u root mysql
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
安装过程中没有设置过root密码,不清楚root密码,搜索了网上一些资料,大致有下面一些情况:
1:有些博客说root的随机密码位于/root/.mysql_secret中,但是我这个版本根本没有/root/.mysql_secret文件。搜索到一篇文章,大意如下所示(没有确认)。到现在也没有明白,我这个版本为什么没有生成这个文件?
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO) :表示没有生成root的临时密码
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES) :表示生成了root的临时密码。
2:有些资料说root的默认密码为空,经过确认那是以前的老版本,Mysql 5.6及以后版本出处于安全考虑,root密码已经不为空了。
解决方法:
具体的解决方法参考文章:http://www.vcerror.com/?p=1640
0 0
- Linux mysql 5.6: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- Linux mysql 5.6: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- [linux][mysql]ERROR 1045 (28000) : Access denied for user 'root'@'localhost' (using password:No)错误
- Linux下mysql出错:ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- mysql-->ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- mysql Error 1045(28000) Access Denied for user 'root'@'localhost' (Using password:NO)
- mysql解决ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- MySQL: Error 1045 (28000): Access denied for user ‘root’@'localhost’ (using password: NO)
- centOS下mysql-ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- mysql问题:ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- mysql提示ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- mysql问题ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- 新安装mysql ERROR 1045 (28000): Access denied for user root@localhost (using password: NO)
- 解决MySQL 报错:ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- Mysql没有初始密码(ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO))
- mysql GRANT with ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO
- MySQL:ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- Ubuntu下 MySQL的“ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)”
- GIT使用总结
- Android中实现定时器的三种方法
- XUtils中Bitmap设置的图片如何平铺满
- 1.Linux网络栈下两层实现
- ViewPager实现可以自动滚动的广告展示
- Linux mysql 5.6: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
- Spring MVC拦截器配置及其原理分析
- OpenWrt的swconfig结构框架
- HTML和CSS的关键:盒子模型(Box model)
- Scala : 主构造器、私有构造器、构造器重载
- 济宁宋君豪
- SecureCRT自动断开与服务端连接的解决办法
- 撤销功能的实现——备忘录模式(Memento Pattern)
- 解决PHP Warning: Cannot modify header information - headers already sent by...