Pinterest Stumbleupon Whatsapp

Once you start getting more comfortable with using Linux, you’ll want to start making use of some great utilities that can make you vastly more productive. Arguably one of the most important utilities to learn is SSH. With it, you can control a different machine as if you were sitting directly at it. This can allow you to set up headless machines such as with a Raspberry Pi Setting Up Your Raspberry Pi For Headless Use With SSH Setting Up Your Raspberry Pi For Headless Use With SSH The Raspberry Pi can accept SSH commands when connected to a local network (either by Ethernet or Wi-Fi), enabling you to easily set it up. The benefits of SSH go beyond upsetting the daily screening... Read More .

How do you set it up, on both the client and server sides? We’ll take you through a basic installation so that you can connect between the two.

What’s SSH?

Simply put, SSH (Secure Shell) allows you to connect to a different computer and gain terminal access What SSH Is & How It's Different From FTP [Technology Explained] What SSH Is & How It's Different From FTP [Technology Explained] Read More to it despite not physically sitting right in front of it. SSH doesn’t give you access to the graphical desktop environment (normally, at least), but it will give you terminal access. That alone is a good enough reason to brush up on your terminal skills An A-Z of Linux - 40 Essential Commands You Should Know An A-Z of Linux - 40 Essential Commands You Should Know Linux is the oft-ignored third wheel to Windows and Mac. Yes, over the past decade, the open source operating system has gained a lot of traction, but it’s still a far cry from being considered... Read More . Once you’re connected to the other computer, you can do virtually whatever you want, especially if you have root access on the remote user account.

Client-Side Installation

Getting SSH installed is really easy, and only takes a few other bits of information to get going. On the computer which you’d like to use to connect to other computers, you’ll need to install the OpenSSH client if it isn’t already. On Ubuntu systems this can be done with sudo apt-get install openssh-client. Once that installation completes, you’re already good to go with one computer.

Alternatively, you could also install PuTTY if you are used to it or other SSH clients on Windows 4 Easy Ways to Use SSH In Windows 4 Easy Ways to Use SSH In Windows SSH is the de facto solution for securely accessing remote terminals on Linux and other UNIX-like systems. If you have a remote SSH server you want to access, you'll have to download an SSH client.... Read More , even though I personally still prefer using the terminal directly instead of PuTTY. However, for those you want it, they can install it with the command sudo apt-get install putty.

Server-Side Installation

On every computer that you want to connect to, you’ll need to install the server-side part of the software if it isn’t already. You can do so on Ubuntu systems with the command sudo apt-get install openssh-server. Once this is installed, all of the needed software is installed.


Determine IP Address


Now, you need to know the IP address (or web address) that you can use to get to the computer you want to connect to. If the computer is connected to the same network as yours, it’d be best to use the local IP address (i.e. rather than the public IP address (i.e.

Otherwise, if the computer is located on a different network, you’ll need to use the public IP address and make sure that port 22 is forwarded to the computer in question, if possible and needed.

If you need to know the local IP address, you can run the command ifconfig and then see what IP address it gives you. For the public IP address, you can visit a site like and have it tell you.

Connecting via SSH

Once you have the IP address you need to use, make sure you also have a username and password that works on the machine you’re connecting to, and then run the command ssh username@, replacing username with the actual username and with the actual IP address you need to use. Hit Enter, and it will ask you for the user’s password. With a correct password, you’ll get a functioning terminal prompt — you’re now logged into the remote computer!


If you are having any issues, these are the possible issues:

  • Software isn’t installed on either computer
  • Username/password is wrong
  • IP address is wrong
  • A firewall somewhere along the way is blocking or not forwarding port 22

Double-check all of these points and you should be able to connect. If not, you might have a complex problem on your hands.

What Do You Use SSH For?

SSH can become a really useful tool if you have to manage multiple Linux computers — you can work on all of them from just one system. Even if you don’t have any serious work that SSH can help with, it’s a quick and easy little experiment you can try out for yourself. I always find it a little awesome whenever I send a shutdown command to a remote computer and then see the computer shutting down without me physically touching it.

What great uses have you found for SSH? What advanced things can you suggest people do with SSH? Let us know in the comments!

Leave a Reply

Your email address will not be published. Required fields are marked *