DBeaver is an awesome SQL client and database management tool.
It comes with drivers for the most popular databases, including MySQL, PostgreSQL, SQLite and many others, meaning you can learn one tool and use it across projects built on different technology stacks. How awesome is that?
Bellow are the steps you can use to connect your DBeaver client to a remote database server via SSH.
Note that you only need to do these steps once. The connection configurations will be saved and you can re-use them by right-click + connect.
This guide is created using DBeaver version 6.3.
Create a new connection by right clicking in your Database Navigator area.
Fill details under the SSH tab, and click Test tunnel configuration.
You should see a success message if the details were correct.
Now that DBeaver can connect via SSH, let’s go back to the General tab and fill in the database credentials:
Clicking Test Connection, you should see a success message. Click Finish.
If your server requires an openssh private key to login, follow the bellow steps:
You can do it by opening Help/Install New Software… and typing the following link: https://dbeaver.io/update/sshj/latest/
Use the same steps as Method 1, but adjust as follows:
- On the SSH details menu (step 2), provide the password for your encrypted private key file.
Select SSHJ, under Implementation.
- Change Authentication Method to Public Key.
Select your Private Key
- Click Test tunnel configuration and Finish.
If you need additional help, this link may be very useful.