windows mysql root

windows mysql reset root

Posted on Updated on

http://dev.mysql.com/doc/mysql-windows-excerpt/5.0/en/resetting-permissions-windows.html

1. stop mysql service.
2. edit a file abcd.sql
UPDATE mysql.user SET Password=PASSWORD(‘MyNewPass’) WHERE User=’root’;
FLUSH PRIVILEGES;
3. mysqld.exe –console –init-file=abcd.sql
4. new root password = MyNewPass

廣告