Cannot Connect to Database Server mysql workbench

后端 未结 5 2011
悲&欢浪女
悲&欢浪女 2021-01-06 11:28

I\'m trying to connect to mysql workbench but I get the following error

Error Message Cannot Connect to Database Server

Your connection attempt failed for us

5条回答
  •  我在风中等你
    2021-01-06 11:57

    I faced similar issue and resolved it by following these steps:

    1. In the terminal, execute this command mysql -u root -p -h localhost -P 3306
    2. Enter the password
    3. This will be displayed Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 18 Server version: 8.0.16 Homebrew
    4. Now do, ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root';
    5. Now you should be able to login and connect to DB in the workbench with password 'root'

提交回复
热议问题