Navicat SSH Issues

4.7k views Asked by At

I'm having trouble connecting to Navicat using an SSH Tunnel and seem to have all my ducks in a row, so wondering if anyone else who had done this has had success:

I set up a normal (TCP) user and checked the connection (host, port, user, password, and remote access ip added in cpanel) to make sure it worked.

As per the instructions, I then went to the SSH tab and enabled it ([x] SSH Tunnel).

I added the same IP for host, then 22 for port, then added root as user, selected password as authentication and then entered the root password.

I keep getting a host.mydomainame.com cannot connect to this mysql host.

I know it is working because: a) if I use the wrong user/pwd I simply get a 'could not create tunnel' error b) my host confirms that an SSH connection IS created the moment I connect with the correct root/pwd combo (even though the error message is generated on my side)

BTW as per Navicat I ensured that AllowTcpForwarding is set to yes.

I also confirmed using bithive I can connect to the same server from the same IP with the same user.

2

There are 2 answers

0
qpaycm On

In my case, I used a PuTTYgen -> Load an existing private key file -> Conversions -> Export ssh.com key and that solved my issue!

1
Mark H On

Figured this out so thought I'd update so anyone else having issue can make this work. Answer turns out to be pretty basic.

The 'General Tab' where you set your MySql User has to have localhost, not the hostname or ip as it usually does, since the SSH Tunnel Tab creates the connection to that host first.