該錯誤只在Windows系統(tǒng)上出現(xiàn),Linux下好像好沒有,據(jù)說這個錯誤已經(jīng)存在n年了,有人extremely dispointed that it still exists here in 2009!
錯誤的原因更令人抓狂,那就是mysql server instance config wizard根本沒有為你設(shè)密碼,于是root密碼是空!實在不明白如果沒有為我設(shè)密碼那中間為什么叫我設(shè)個密碼。
-
解決辦法:
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: 國內(nèi)和國外的水平真是差得遠,國內(nèi)的磚家們只會告訴你是和以前安裝的mysql版本沖突了,把它卸干凈,再把配置啊注冊表啊都刪干凈(簡直就是既然我不知道是哪錯了那就是全錯了),再重裝。而問題根本沒解決。。。。。。人國外的卻能一針見血地指出問題之所在。 本文出自:億恩科技【1tcdy.com】
服務(wù)器租用/服務(wù)器托管中國五強!虛擬主機域名注冊頂級提供商!15年品質(zhì)保障!--億恩科技[ENKJ.COM]
|