2

How can I allow remote connections to databases with MySQL Workbench?

Trying to connect to a database on an external host and it refuses the connection.

Port 3306 is forwarded correctly.

  • Did you configure a user for remote access in the MySQL database and give that user the proper permissions to access the DB you want it to access? Can you provide the specific error text or an error code? – b_laoshi Jun 5 '17 at 0:25
2

From the server:

GRANT ALL PRIVILEGES ON *.* TO '{USER}'@'{IP{' IDENTIFIED BY '{PASSWORD}' with grant option;
  • {IP} is the IP you want to allow access. You can use % to accept any IP address
  • {USERNAME} is the user you use to connect
  • {PASSWORD} the password you use to connect
  • To confirm the change do ...

    FLUSH PRIVILEGES;
    

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.