How To Enable SSH on Ubuntu 22.04

SSH is a communication protocol to communicate between two different machines, one is the client and the other is the host. In this write-up, we have installed the OpenSSH server in Ubuntu 22.04 and used it to connect to a remote machine.

Enable ssh on ubuntu 22.04; In this tutorial, i am going to show you how to enable ssh and use ssh on ubuntu 22.04 using command line or terminal.

How to Enable and Use SSH on Ubuntu 22.04

Use the below given steps to enable and use ssh on ubuntu 22.04:

  • Step 1 – Update Dependencies
  • Step 2 – Install Openssh
  • Step 3 – Check Status of SSH
  • Step 4 – Allow Connection
  • Step 5 – Connect to SSH Server

Step 1 – Update Dependencies

Run the following command on the command prompt to update dependencies:

sudo apt update 

Step 2 – Install Openssh

Run the following commands to install the OpenSSH server on system:

sudo apt install openssh-server 

Step 3 – Check Status of SSH

Once the packages installation has been finished, execute the following command on command prompt to check SSH service status:

sudo systemctl status ssh 

Step 4 – Allow Connection

Run the following command on command prompt to allow SSH for remote users; is as follows:

sudo ufw allow ssh
sudo ufw enable && sudo ufw reload

Step 5 – Connect to SSH Server

Run the following command with username and ip addres to connect ssh server:

ssh [email protected]_host 

Conclusion

Through this tutorial, i have shown to you how to install, connect and enable ssh on ubuntu 22.04 system.

Be First to Comment

Leave a Reply

Your email address will not be published.