SSH known as Secure Shell is a protocol for operating network services securely. It is needed especially if you are for example planning on managing your Linux Server from Windows.
Installation:
SSH protocol can be installed automatically during ubuntu fresh installation. An option is being displayed which merely needs to be marked with an ‘x’ for an automated installation.
Lets presume this was not the case and you need to install this afterwords. The procedure is very simple.
- Update all linux libraries first:
$ sudo apt-get update
- Upgrade linux installation if necessary
$ sudo apt-get upgrade
- Install SSH
$ sudo apt install ssh
Please confirm and allow creation of an ssh key.
How to connect to ssh Linux from Windows?
On your windows machine do the following:
- Start CMD as Administrator
- Start Power Shell
C:\WINDOWS\system32> powershell
3. SSH your linux server:
PS C:\WINDOWS\system32> ssh linuxusername@192.168.100.10
Replace ‘linuxusername’ with the your linux username and replace ‘192.168.100.10’ with the IP address of your linux installation.
After doing so you will be prompted to enter the password of the linux username and you will be asked to accept the ssh key. After accepting it the key will be saved on windows machine as a trusted ssh keys.
Your are now logged into linux from a windows Command Prompt.
You might also consider setting up the appropriate firewall rules on your linux server especially opening the port 22 to gain access. You can follow this post to learn how to use, configure the ufw firewall