Run SSH terminal
You can launch an SSH Session right from IntelliJ IDEA. By running commands in a dedicated SSH terminal, you can access data on a remote Web server or a Vagrant instance (virtual machine) via an SSH tunnel, mainly upload and download files.
Enable the FTP/SFTP/WebDAV Connectivity plugin
This functionality relies on the FTP/SFTP/WebDAV Connectivity plugin, which is bundled and enabled in IntelliJ IDEA by default. If the relevant features are not available, make sure that you did not disable the plugin.
Press Ctrl+Alt+S to open settings and then select .
Find the FTP/SFTP/WebDAV Connectivity plugin and click Enable.
Set up the SSH terminal
Make sure the remote computer has an SSH server and that you have an account with access to it.
Register an account on the SSH server in the destination environment and generate a pair of SSH keys or a password, depending on the server policy.
Select the remote environment and configure the SSH terminal:
In the Settings dialog (Ctrl+Alt+S) , go to .
In the Connection settings area, select the remote environment:
Current Vagrant: select this option to have the commands in the SSH Terminal executed on the currently running Vagrant virtual machine.
SSH configuration: select this option to have the commands in the SSH Terminal executed on the local or remote Web server accessible through one of the SSH configurations.
Select SSH configuration on every run: if this option is selected, you will have to choose the desired configuration from the popup, every time you choose from the main menu.
If the desired SSH configuration does not appear in the list, click the Set up configurations link, and define one in the SSH Configurations page.
To use the same SSH connection each time, select an SSH configuration. To choose a connection whenever you start a session, select Select SSH configuration on every run.
From the Default encoding list, select the encoding to use in the SSH terminal.
Launch the SSH terminal
In the main menu, go to . Alternatively, invoke the Help | Find Action Ctrl+Shift+A dialog, search for start ssh.., and select Start SSH Session.
Depending on the connection settings defined on the page of the Settings dialog (Ctrl+Alt+S) , the following types of behavior are possible:
If the Current Vagrant option has been selected, the SSH Terminal will provide access to the currently running Vagrant virtual machine.
For more information, refer to Vagrant.
If the SSH configuration option has been selected, the SSH Terminal will provide control over the data on the server accessible through the SSH configuration selected from the list. For more information, refer to Create SSH configurations.
If the Select SSH configuration on every run option has been selected, IntelliJ IDEA will show a list to choose the desired SSH configuration from.
If no Vagrant virtual machine or SSH connection has been previously set up in IntelliJ IDEA, an SSH Session dialog opens prompting you to create an SSH configuration.
View SSH logs
To troubleshoot an SSH connection, check the IDE logs. For authentication errors, also check the SSH server logs or ask the server administrator. Their location depends on the server operating system and configuration.
For example, on a Fedora server, run sudo journalctl -u sshd.service to view the SSH server logs. These logs can help identify authentication failures and rejected connections.