dtrpv60860 2014-07-04 03:50
浏览 136

在Localhost上使用XAMPP重置MySQL Root密码

So for the past hour I've been trying to figure out how to reset my 'root' password for MySQL as I cannot log into PHPMyAdmin. I've tried changing the password in the config.inc.php file and searching through other methods. I cannot find a successful way. A few months ago I changed it as a test password but now I forget what it was. If anyone can help, that would be great. (I'm running on a Windows computer).

  • 写回答

13条回答 默认 最新

  • dongxingchang9345 2014-07-04 03:53
    关注

    You want to edit this file: "\xampp\phpMyAdmin\config.inc.php"

    change this line:

    $cfg['Servers'][$i]['password'] = 'WhateverPassword';
    

    to whatever your password is. If you don't remember your password, then run this command within the Shell:

    mysqladmin.exe -u root password WhateverPassword
    

    where WhateverPassword is your new password.

    评论

报告相同问题?