0
转自:KeLe's Blog
1)停止windows服务中的mysql实例
2)使用–skip-grant-tables 参数启动mysql,这种模式下,无需root密码就可以登陆mysql.
mysqld-max-nt –skip-grant-tables
3)登陆mysql,修改密码
C:\Documents and Settings\Administrator>mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 5.0.27-community-max-nt
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> use mysql;
Database changed
mysql> update user set password=password("52crack" where user="root";
Query OK, 1 row affected (0.07 sec)
Rows matched: 1 Changed: 1 Warnings: 0
4)然后重新启动mysql. 在这里,我不知道如何正常停止–skip-grant-tables起来的mysqld-max-nt 进程,只能杀掉了。
用tasklist和taskkill ,都是WIN自带的。
然后mysql -uroot -proot就可以登陆了。
1)停止windows服务中的mysql实例
2)使用–skip-grant-tables 参数启动mysql,这种模式下,无需root密码就可以登陆mysql.
mysqld-max-nt –skip-grant-tables
3)登陆mysql,修改密码
C:\Documents and Settings\Administrator>mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 5.0.27-community-max-nt
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> use mysql;
Database changed
mysql> update user set password=password("52crack" where user="root";
Query OK, 1 row affected (0.07 sec)
Rows matched: 1 Changed: 1 Warnings: 0
4)然后重新启动mysql. 在这里,我不知道如何正常停止–skip-grant-tables起来的mysqld-max-nt 进程,只能杀掉了。
用tasklist和taskkill ,都是WIN自带的。
然后mysql -uroot -proot就可以登陆了。
泡妞高手的经典三十六
Office2003

2007/07/05
11:55
868

















