+5 votes
334 views
Install SSH on Ubuntu 20.04

in Linux / Unix by (552k points)
reopened | 334 views

1 Answer

+3 votes
Best answer

Install SSH protocol in Ubuntu 20.04

SSH (Secure Shell) is a remote administration protocol thanks to which we have the possibility to control, manage and edit variables or processes on remote servers through the Internet using an authentication method. SSH gives us a way with which it is possible to authenticate a remote user, to be able to transfer elements from the client to the host and vice versa..

 

SSH encryption
The SSH protocol offers us different forms of encryption such as:

 

  • Symmetric encryption
  • Asymmetric encryption
  • Hashing

 

 

SSH syntax
The basic syntax of SSH is as follows:
 ssh {user} @ {host} 

 

 

SSH operation
The mechanism for using SSH is simple, firstly, it tells Ubuntu that we will use a secure shell connection and with the encryption mechanisms (ssh), then we enter the user (user) with which we are going to authenticate and finally we set the destination (host).

 

Remember that when we use SSH, everything we do in the session (user authentication, commands, file transfers) will always be encrypted in order to protect data from any attack on the network.

 

With SSH it is possible to make use of SSH keys with which we can automate access to remote servers and computers, optimizing security..

 

Without further ado, let's see how to install SSH in Ubuntu 20.04.

 

To stay up to date, remember to subscribe to our YouTube channel!   SUBSCRIBE

 

 

Install SSH protocol in Ubuntu 20.04

 

Step 1

By default, basic SSH is already installed on the system, but with some restrictions, in the Ubuntu 20.04 terminal we execute the following:
 Ssh 
Step 2

As a result we will see all the options for using the SSH protocol:

 

 

 

image

 

 

Step 3

To check its use, we are going to try to establish a local connection, we execute the following:
 ssh localhost 
image

 

 

Step 4

As we can see, by default port 22 (of SSH) rejects the connection, in this case we must install the protocol of the SSH server with the following command:
 sudo apt-get install openssh-server 
image

 

 

Step 5

We confirm the installation with the letter S:

 

image

 

 

Step 6

We can check the status of the SSH service in Ubuntu 20.04 with the following command:
 sudo service ssh status 
image

 

 

Step 7

As we can see, its status is active and running, we can check access to the local host again:
 ssh localhost 
image

 

 

Step 8

If we do not accept the connection, an error will appear, so when executing the command it is required to enter "yes" to access with SSH.

 

After this we can access the SSH configuration file with an editor: There we can see the default SSH port (22), we can edit it if necessary, but we always recommend leaving the default values..

 sudo nano / etc / ssh / sshd_config 
image

 

With these simple steps we have installed SSH in Ubuntu 20.04.

 


by (3.5m points)

Related questions

+5 votes
1 answer
asked Oct 6, 2020 in Linux / Unix by backtothefuture (552k points) | 898 views
+4 votes
1 answer
asked Sep 29, 2020 in Linux / Unix by backtothefuture (552k points) | 1.4k views
+3 votes
1 answer
asked Sep 28, 2020 in Linux / Unix by backtothefuture (552k points) | 498 views
+5 votes
1 answer
asked Sep 28, 2020 in Linux / Unix by backtothefuture (552k points) | 1.9k views
+4 votes
1 answer
asked Sep 25, 2020 in Linux / Unix by backtothefuture (552k points) | 660 views
Sponsored articles cost $40 per post. You can contact us via Feedback

Most popular questions within the last 30 days

10,659 questions
10,791 answers
510 comments
3 users