Skip to main content

VPS: Installation of SSH

This guide was created with the following products:

(Details may vary with products from different providers but the main concepts remain the same)

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 (SSH)

If you wish to learn more about improving your security on your server, we highly recommend viewing our 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

Conclusion

Congratulations, you have successfully installed and configured the SSH service! If you have any further questions or problems, please contact our support team, who are available to help you every day!