To connect and set up properly with a command line, I "simply" have to do:
ssh <MY_USERNAME>@<URL> -L 1139:arcade:139
<MY_PASSWORD>
psql -h postgres
\c ift2935
set search_path to inscriptions_devoir;
However, I've been tempted to use a more complex tool than the command line to explore the database and try out different SQL commands. Being a fan of JetBrains
, I've decided to try out DataGrip
.
I have indeed read the actual help page but it doesn't provide me with the information I need.
I lack the understanding of the jargon to know the correspondance, in terms, between the different lines I had to enter and the actual field-names that I am supposed to enter in DataGrip
.
My question is quite simple: what and where do I type the stuff ?
I faced this issue too. So want to explain others how i managed to do it. lets say for example your remote server ip address is 192.128.11.120. Most of the time while tunneling the localhost/127.0.0.1 is used as the host ip address as in such scenarios the localhost ip is set as the bind address in the mysql config.
Here is the step by step guide on setup to connect to MySQL using SSH tunnel.
1 - Go to SSH/SSL tab and select 'Use SSH tunnel'
2 - Click and do shift+enter or click three dots [...] to open SSH Configurations. From there click + sign to add a new configurations. Fill the form with your remote server ssh configurations.
After that click 'Test Connection' to test whether SSH configuration is correct. If it works Click 'Apply' and 'OK' to save it.
Now SSH is configured for DataGrip.
3 - Go to 'General' Tab to add the MySQL related entries. One thing to keep in mind is that most of the time the bind address is set to localhost/127.0.0.1 in MySql to make it secure on the remote servers to enable only ssh connections. In such cases the remote ip(in this case 192.128.11.120) wont work. So, use 127.0.0.1. Click test connection to check whether the MySQL connection works over SSH.
4 - If it works, Click 'Apply' and 'OK' to save it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With