3

I'm new to MySQL and Vagrant and spent several hours trying to set both up. I can connect to MySQL from the command line with:

mysql --host=127.0.0.1 --user=root --password=[my_password]

I'm trying to connect with Sequel Pro and following a couple tutorials have set up Vagrant/MySQL correctly, I believe. I'm trying to connect thru SSH and tried many combinations of username/password. I believe the correct inputs are:

MySQL Host: 127.0.0.1

username: root

password: [my_password]

SSH Host: 127.0.0.1

SSH User: vagrant

SSH Key: insecure_private_key

SSH Port: 2222

however I'm still getting the error "The SSH Tunnel could not authenticate with the remote host. Please check your password and ensure you still have access."

Any help is appreciated, thanks

KM617
  • 137
  • 1
  • 3
  • 16

4 Answers4

4

You need to choose SSH connection type and select the correct private key.

Sequel Pro SSH connection with private key

For Vagrant 1.6 and older, the private key is located in ~/.vagrant.d/insecure_private_key. For Vagrant 1.7 and above, the private key is located in .vagrant/machines/[vm_name]/virtualbox/private_key where the Vagrantfile is located.

Hanxue
  • 12,243
  • 18
  • 88
  • 130
2

Try the following configuration and leave everything else blank. (Of course specify MySQL root password if you've set it up.)

MySQL Host: 127.0.0.1 Username: root Port: 3306 SSH Host: 127.0.0.1 SSH User: vagrant SSH Key: ~/.vagrant.d/insecure_private_key SSH Port: 2222

greenhorn
  • 1,097
  • 6
  • 10
2

I got the same error and this solved the issue for me.

ssh-add -K ~/.ssh/id_rsa
QuakeCore
  • 1,886
  • 2
  • 15
  • 33
0

For me work added my key identity

ssh-add -K ~/.ssh/id_rsa