Reputation: 6743
I am new to MySQL. I have installed MySQL 5.6 in Windows 7 with user root and given password to it. But when I start MySQL Workbench and try to connect database, I am getting an error.
My try:
Connect to Database:
Connect to MySQL Server:
Error:
Then I tried to reset password with command prompt:
Please help me, I am new to MySQL, not getting what to do.
Thanks
Upvotes: 1
Views: 3469
Reputation: 5156
You can resolve this issue using these steps.
1.open the terminal
2.exectute the command - sudo mysql -u root
3.then,execute - ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'new_password';
(*replace the "new_password" with your new password"
4.exit;
5.now check the connection...It will work :)
Upvotes: 1
Reputation: 7961
It's possible that your setup is not listening for IP connections and is only listening on a local socket. Try:
mysql -u root
If you have already set a root password, try:
mysql -u root -p
on the command prompt. Or try removing the hostname from workbench.
Upvotes: 1
Reputation: 1052
It seems you do not have access for such task, exit the application and re-start it as administrator . Run As Administrator
Upvotes: 0