Skip to main content

Server: Installation of SSH

Introduction

Secure Shell (SSH) is a secure protocol that enables safe and encrypted access to remote systems. It ensures the confidentiality and integrity of data transmitted across networks.

In this guide, you will understand how to install or reinstall the SSH Server for a range of Linux Distributions that we currently offer across our VPS servers. Most Linux Distros offered through our VPS servers, are equipped with an SSH Server by default which means you can easily manage it through the product's webinterface. You can view how to do this via our guide: Initial Access with SSH

If you wish to learn more about improving your security on your server, we highly recommend viewing our Linux Security Tips guide which promotes a range of tools and services that can help secure your server further.

Installation

To start the installation process, access your server via VNC. You can follow these steps using the VNC Console.

info

If you want to re-install the SSH server, make sure that you uninstall it first. You can do so through the command: yum remove openssh.

Before installing the SSH server, make sure your system is up to date. Run the following command:

yum update

Now proceed to install the SSH server using following command:

yum install openssh-server

Once it has finished installing, you can start the SSH server service with the following command:

systemctl start sshd

Ensure that you enable the service to automatically start on system boot. You can do this through the following command:

systemctl enable sshd

Enabling root login

To enable root login, you need to edit the openssh configuration file. In this guide, we will use "nano" as editor.

info

If "nano" is not already installed, it must be installed first. To do so, use the following command: yum install nano

Proceed to open the configuration file by running:

nano /etc/ssh/sshd_config 

Using arrows keys to navigate, search for the following line:

#PermitRootLogin prohibit-password

Change this to the following, which enables remote root login:

PermitRootLogin yes

Finally, restart the SSH Server in order to apply the new configuration by using the following command:

systemctl restart sshd

You have now successfully installed the SSH Service on your server and can now access your server via SSH.