MySQL with SSH tunnel configuration

Describe the problem/error/question

I’m trying to use the MySQL node with the SSH tunnel option and a private key.

What is the error message (if any)?

When I hit save, it loads indefinitely. In the browser’s console, I can see an HTTP 500 error on the route https://doctr.app.n8n.cloud/rest/credentials/test and the response indicates “Invalid username”.

I tested the credentials with MySQL Workbench and they work fine.

Information on your n8n setup

  • n8n version:: Cloud 1.1.1

Hi @Elie_Sauveterre, welcome to the community!

I am so sorry you’re having trouble. I was able to reproduce this problem on my own n8n cloud account and shall add this to our engineering backlog for a closer look and a fix

Thanks @MutedJam . Do you have a delivery date you can share?

Hey @Elie_Sauveterre,

Locally I have this fixed but I am also working on some other fixes in the same PR around similar problems but I expect to have the fixes in place today / tomorrow so in theory it may be in the next release so for cloud we would be looking at possibly next week depending on when we release and if it makes it.

As a temporary solution though using a tunnel with a password will work so you could use that as an alternative until fixed.

1 Like

Thanks @Jon . I will try that.

Hi @Jon ,

Any update on this?
We are working with a MySQL server thats only available behind a private key based SSH tunnel

Hey @Sander,

Welcome to the community :raised_hands:

This has been fixed in this PR: fix: Fix issue with authentication keys for FTP, MQTT, MySQL, Postgres, RabbitMQ and SSH nodes by Joffcom · Pull Request #6824 · n8n-io/n8n · GitHub and it just needs merging so that it can be available in a future release.

Hi @Jon

Great! looking forward to it!

Hi @Jon ,

I just see its merged and we have installed version 1.2.0 already :smile:
The error is gone!
However now we get this error: Cannot parse privateKey: Unsupported key format
We try to insert an ssh-rsa private key, what are the supported formats?

Hey @Sander,

It should support any SSH key format unless I messed up the last change, Give me 2 minutes

Thanks!
Here the exact response from the console.

1 Like

Hey @Sander,

I have put in a fix for this, I broke it last minute when I updated the formatting function.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.