您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

解决MySQL安装时1045错误的方法

2024/3/19 11:11:20发布28次查看
该错误只在windows系统上出现,linux下好像好没有,据说这个错误已经存在n年了,有人extremely dispointed that it still exists
该错误只在windows系统上出现,linux下好像好没有,据说这个错误已经存在n年了,有人extremely dispointed that it still exists here in 2009!
错误的原因更令人抓狂,,那就是mysql server instance config wizard根本没有为你设密码,于是root密码是空!实在不明白如果没有为我设密码那中间为什么叫我设个密码。
解决办法:
i clicked skip on the dialog that states the error 1045...
then cancelled the mysql server instance config wizard
now...
open a command prompt type mysql -u root -p then hit
enter again when it requests a password.
you should now have access to the mysql monitor...
type the following at the prompts...
mysql>use mysql
mysql>select user, host, password from user;
# now you should see that u have 3 entries
+-----------------------------+
| user | host | password |
+-----------------------------+
| root | localhost | |
| root | 127.0.0.1 | |
| | localhost | |
+-----------------------------+
mysql> delete from user where host=localhost and user=;
mysql> update user set password=password(xxxx) where user=root;
mysql> flush tables;
mysql> flush privileges;
mysql> quit
now the mysql table should be updated and everything fixed.
try it out...
然后就可以用config wizard跑一遍了。
ps: 国内和国外的水平真是差得远,国内的砖家们只会告诉你是和以前安装的mysql版本冲突了,把它卸干净,再把配置啊注册表啊都删干净(简直就是既然我不知道是哪错了那就是全错了),再重装。而问题根本没解决。。。。。。人国外的却能一针见血地指出问题之所在。
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product