MySQL and SSH Tunnel

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.

When i try to create the same conection using SSH node it’s work fine.

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

Information on your n8n setup

Debug info

core

  • n8nVersion: 1.95.3
  • platform: docker (self-hosted)
  • nodeJsVersion: 20.19.2
  • database: postgres
  • executionMode: scaling (single-main)
  • concurrency: -1
  • license: enterprise (production)

storage

  • success: all
  • error: all
  • progress: false
  • manual: true
  • binaryMode: memory

pruning

  • enabled: true
  • maxAge: 336 hours
  • maxCount: 10000 executions

Hey @A_Cevallos,

I tried the same it did load indefinitely.
Just close it and try a “Select” Operation it worked for me.

Hi @mrrobot thanks for your answer.

I can not reach that screen because my error happens when creating the connection. It keeps in testing, http response is 500 and nodes logs complain about connection error. The exactly same ssh credentials works fine as normal ssh credentials.

hey @A_Cevallos ,

i have mysql running as container and n8n as well.

host : machine_ip
Database: db_name
User : mysql_user
Password : <>
Port : 3306
Connect Timeout : 10000

SSL : off
SSH Tunnel : on

SSH Authenticate with : Password
SSH Host : machine_ip
SSH Port :  22 (or custom port)
SSH Passowrd : <>

What is your setup mysql is on another machine ?

oh, yes, the mysql instance is out of n8n docker and so, in other server… but I can connect to that mysql with ssh tunneling in workbench or other db managers…