Reset MySQL password

Some days back  i just forget this password for Mysql and there is very easy way to reset this password, simply follow below steps : (Windows XP)

  1. Go to control panel > administrative tasks > services
  2. Select mysql service from right pane
  3. right click on it and 'STOP' the service
  4. There is a way to start the server with special init file which you can create as follows :
UPDATE mysql.user SET Password=PASSWORD('girish') WHERE User='root';
FLUSH PRIVILEGES;

  • Copy above 2 lines and paste it in notepad and save this file as  : mysqlpwdreset.txt 
  • Now fire up : C:\mysql\bin\mysqld-nt --init-file=C:\\mysqlpwdreset.txt
For More Information Click here
Thats it! Now Fire up your mysql and enter this new password !
Thank You,

0 comments:

Post a Comment