Ubuntu Linux install OpenSSH server

To install OpenSSH server on Ubuntu Linux, you can use the apt package manager. Here are the steps to do this:

  1. Open the terminal and update the package list by running the following command:
sudo apt update
  1. Install OpenSSH server by running the following command:
sudo apt install openssh-server
  1. Verify that the SSH service is running by checking its status:
sudo systemctl status ssh
  1. If the service is not running, you can start it by running the following command:
sudo systemctl start ssh
  1. To make sure that SSH service starts automatically at boot time, run the following command
sudo systemctl enable ssh
  1. To check the version of OpenSSH Server
ssh -V
  1. To configure the SSH server, you can edit the /etc/ssh/sshd_config file. This file contains various options for configuring the SSH server, such as setting the port number and disabling password authentication.
  2. To connect to your server via SSH, you can use the ssh command from your local machine:
ssh user@server_ip

You can also use the ssh-copy-id command to setup the public key authentication. This will allow you to log in to your server without entering your password every time.

Leave a Comment