October 14, 2005

忘記 MySQL 的 root 密碼 >.<

年紀大了,忘了就是忘了,怎麼辦?

只要有系統管理員的權限都還有得救!

首先,用系統管理員的帳號登入,如 Linux 的 root 或 Windows 的 Administrator。

再來結束 mysql 的 process,Windows 叫出工作管理員,Linux 可以執行以下的指令:

killall mysqld

接下來,用以下的指令啟動並進入 MySQL:

mysqld -u root --skip-grant-tables &

mysql

進入 MySQL 的命令提示列後:

use mysql;
UPDATE user SET password=password('new password') where user='root';
FLUSH PRIVILEGES;

這樣就OK囉 ^^

由 tedyeng 發表於 October 14, 2005 10:23 PM
迴響

Thanks for your sharing, good job!

Posted by: gucci men shoes 發表於 June 8, 2010 01:31 PM

Thank you for this great blog information!I'm finding this whole blogging world a great resource for any topic, and really inspirational.

Posted by: shopping stores 發表於 July 1, 2010 02:44 AM

謝謝,我也給忘了,剛好看到你這篇文章

Posted by: air max 95 發表於 August 15, 2010 11:39 PM

密碼我都是記錄到本子上,記不住啊

Posted by: cheap makeup 發表於 August 17, 2010 03:31 PM

I am not much into reading, but somehow I got to read nice information on your site. Simple to understand and helpful.

Posted by: workout dvds 發表於 August 20, 2010 01:30 AM

谢谢你,我记得怎么做)

Posted by: Apotheke 發表於 August 29, 2010 02:25 AM

I will keep your new article.
Good ! I like it ! Welcome to read following news

Posted by: mac cosmetics wholesale 發表於 September 1, 2010 02:10 PM

I will keep your new article.
Good ! I like it ! Welcome to read following news

http://www.cosmetics-mac.com/blog/

Posted by: cheap mac makeup 發表於 September 1, 2010 02:11 PM
發表迴響









記住我的資訊?





請依上圖輸入檢核碼: