Resetting ROOT password in MySQL 5.6

前端 未结 9 1910
名媛妹妹
名媛妹妹 2020-11-27 17:24

I have been following these instructions for resetting root password for local installation of MySQL 5.6 on Windows 7 laptop.

I stopped

9条回答
  •  余生分开走
    2020-11-27 17:54

    First stop mysql server and follow below steps:

    Go to mysql bin directory on cmd i,e. cd C:\ProgramData\MySQL\MySQL Server 5.6\bin (Its a hidden directory)

    skip grant tables will allow you enter into mysql

    • mysqld.exe --skip-grant-tables

    Open new command prompt or on same command prompt

    • mysql.exe -uroot -p (without any password you can login to mysql)

    run below query to change mysql root password

    • UPDATE mysql.user set password=password('root password') WHERE user='root';
    • flush privileges

    Thats it, Restart mysql and good to go with new password..!!

提交回复
热议问题