1

I'm facing a strange problem here...

My database is in a AWS EC2 and I was used to connect to it through SSH using MySql Workbenh. To do it, I generated a passphrase protected ppk file using puttygen on ubuntu 16.04 and it worked fine.

But after an update, using the same configuration, I receive this error message:

Could not connect the SSH Tunnel

Authentication error. Please check that your username and password are correct and try again. Details (Original exception message): Bad authentication type, the server is not accepting this type of authentication. Allowed ones are: [u'publickey']

So, searching on Google I found this two guys with the same problem: this, and this.

The solution proposed is generate a public open-ssh file and use it, then it was I did:

puttygen myKey.ppk -O public-openssh -o myKey.ppk

And the problem stills the same! I'm not sure if the Workbench update (it is in 6.3.10 version now) caused this issue, but before that I could connect with no problems. I can connect normally in server through ssh in ubuntu terminal.

What I can do?

  • OS: Ubuntu 16.04
  • MySql: Ver 14.14 Distrib 5.7.21
  • MySql Workbench: CE (GPL) 6.3.10

1 Answer 1

1

After a lot of research, I could solve the problem. I found this topic: https://stackoverflow.com/questions/34504232/mysql-workbench-failing-to-connect-via-ssh-due-to-key/38108623 that says that I can't export the private ppk file with passphrase. So, in Ubuntu, using puttygen I generated a private ppk file from my pem key with no passphrase, and from it I generated the private-openssh one.

I tried to connect in workbench and... didn't work! But I got another error, it displayed: not a valid private OPENSSH key.

So, at this point I realized that the most of people with a similar problem in web that could solve the issue uses Windows. Then, as I have a dualboot in my machine, I installed the Putty in Windows and generate de key there. So, it worked! (generating from the ppk with NO passphrase, the one protected by passphrase doesn't works).

If someone face this same problem try this, from a private ppk without passphrase , generate a private-openssh in Windows Putty.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .