devmonster
devmonster

Reputation: 1739

can't connect to MySql with Workbench, although PhpMyAdmin works

I am not able to connect mysql DB from a windows sytem through the workbench. But it's possible via phpMyAdmin.

I tried both standard TCP/IP and Standard TCP/IP over SSH.

Are the password and usernames the same?

Upvotes: 2

Views: 2987

Answers (3)

Bill Karwin
Bill Karwin

Reputation: 562731

You should have included some information in your question:

  • Is MySQL Server running on your PC or on a server over the network?
  • Is PhpMyAdmin running on your PC or on a server over the network?
  • Is MySQL Server running on the same host as PhpMyAdmin, or are they each running on separate servers?
  • What error message do you get when you try to make a connection in MySQL Workbench and it doesn't work? (In general, when asking questions on Stack Overflow, "it doesn't work" is insufficient description of the problem—you should describe what you tried, and the error.)

MySQL connection credentials are a username and password, combined with the IP address range of permitted clients.

The "client" from MySQL Server's perspective is the host running PhpMyAdmin code. You're just using PhpMyAdmin's web interface to direct it to do things for you, but it's the PHP code that connects to MySQL Server.

It's possible that the username and password you're trying to use with MySQL Workbench are authorized only to connect from the host where PhpMyAdmin is installed. This would be my guess.

Upvotes: 0

Anthony
Anthony

Reputation: 107

When setting up the database it should ask you or there should be a setting where you need to allow outside/remote login. Once that is checked as allowed, it should allow you to access. Setup will not allow you to change it later. At least I think.

Upvotes: 1

Sergio
Sergio

Reputation: 4567

Yes, the usernames and passwords should be the same. I think it would be good if you try to connect to your local MySQL server using the MySQL CLI client in your Windows terminal and see what's going on. If you can connect with it then you should be able to connect with Workbench.

Here's a link in the MySQL Documentation that describes common errors related to your issues.

BTW, you should check if you have a recent Workbench version (5.2.40 is the latest release at the time of writting).

Please report back how it goes.

Upvotes: 0

Related Questions