TablePlus / DBngin

DB Engine
https://dbngin.com
995 stars 19 forks source link

Error: Can't connect to local MySQL server through socket '/tmp/mysql.sock' #52

Closed hui453694187 closed 3 years ago

hui453694187 commented 3 years ago

Please fill out the detail below, it helps me investigate the bug:

  1. Driver :MySQL 5.7.23

  2. DBngin build number: Version 3.1 (32)

  3. macOS version:10.14.2

  4. The steps to reproduce this issue:

    When I connect the MySQL, suggesting this exception Error: Can't connect to local MySQL server through socket '/tmp/mysql.sock'

    In addition, if I have a Mysql how local has been installed, How to let DBngin association

texastoast commented 3 years ago

I am also having this issue.

  1. Driver: MySQL 5.7.23
  2. DBngin build number: Version 3.1 (32)
  3. macOS version: 10.15.7
  4. The steps to reproduce this issue:

I tried creating a user and database, then connecting via mysql -u newuser -p newdbname and the same error is returned.

huyphams commented 3 years ago

Hi the socket should be /tmp/mysql_port_number.sock for example: /tmp/mysql_3306.sock

DBngin allows us to create multiple instances so we should not share the same socket path. You can also connect to MySQL via the port 3306 (instead of the socket).

texastoast commented 3 years ago

Confirmed. Running mysql -S /tmp/mysql_3306.sock -u root allows me to connect to a new, passwordless root account. However I can't connect using any password to any account. Opened #53

clementmas commented 2 months ago

I'm only running a single MySQL service on DBngin so I edited it and entered /tmp/mysql.sock in the Socket field. Now I can run the mysql command normally.