Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.

SSH tunnel stopped working

YaronKaplan's profile image YaronKaplan posted 2 months ago in General Permalink

We have a very strange situation in our office.

Connection through SSH tunnel used to work fine. But last week it stopped working when using the office network.

Here what it shows in the log:

/* Connecting to [redacted] via MariaDB or MySQL (SSH tunnel), username yaron_readonly, using password: Yes ... */
/* Attempt to create plink.exe process, waiting 4s for response ... */
/* C:\Program Files\PuTTY\plink.exe -ssh ec2-user@[redacted].compute.amazonaws.com -P 22 -i "C:\Users\Yaron\.ssh\[redacted].ppk" -N -L 3307:[redacted].rds.amazonaws.com:3306 */
/* PLink: Using username "ec2-user". */
/* Can't connect to MySQL server on '127.0.0.1' (10061) */
/* Closing plink.exe process #4716 ... */

And here are some other weird facts:

  • It does work if I connect through the smartphone mobile hotspot instead of the office network
  • It does work if I run the plink line from the command line (and connect to localhost instead of RDS). It also works if I create an SSH tunnel manually and then connect to localhost.
  • MySQL Workbench SSH tunnel does work.

I tried upgrading plink. It did not help.

I am using HeidiSQL 11.3.0.6295, plink 0.76, MySQL 8.0.23 (through Amazon RDS)

Any help would be appreciated!

ansgar's profile image ansgar posted 2 months ago Permalink

You say it works when you manually run the plink command. Is there a difference to the command in the HeidiSQL log?

YaronKaplan's profile image YaronKaplan posted 2 months ago Permalink

No difference - I ran the exact plink command from the log (except that plink prints: "Access granted. Press Return to begin session." and I must press ENTER)

ansgar's profile image ansgar posted 2 months ago Permalink

Ok, in that case it may help to increase the "plink timeout" in Heidi's "SSH tunnel" tab in the session manager. I am mostly using 4 seconds, probably you decreased it to a lower value.

YaronKaplan's profile image YaronKaplan posted 2 months ago Permalink

Yay it works! It was on 4 seconds. Increasing to 10 helps. Thanks a lot!

Please login to leave a reply, or register at first.




Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.