Objective
A Virtual Private Server (VPS) is a virtualized dedicated server. A VPS is not a managed service so you have the full freedom and flexibility to maintain and use it however you choose.
This guide provides some basic information for getting started with a VPS.
OVHcloud is providing you with services for which you are responsible, with regard to their configuration and management. You are therefore responsible for ensuring they function correctly.
Requirements
- a Virtual Private Server in your OVHcloud account
- access to the OVHcloud Control Panel
- login credentials received via email after the installation
Instructions
Log in to the OVHcloud Control Panel, go to the Bare Metal Cloud
section and select your server from the list in the left-hand navigation under Virtual Private Servers
. This dashboard contains important information about your service and allows you to perform essential operations. It will appear differently, depending on the product range of your VPS solution.
-
If you have recently ordered a VPS, its reference name will look like this: vps-XXXXXXX.vps.ovh.net (where X can be a number or a letter).
-
If you are managing an older VPS, you will notice that the reference name is structured differently: vpsXXXX.ovh.net (in which X stands for a number).
For the current VPS range, please continue with the next section, First steps (current VPS range). For an older VPS model, skip to First steps (older VPS range, ranges sold in 2020 and earlier) in this guide.
First steps (current VPS range)
Connecting to your VPS
At the first installation or when reinstalling from the Control Panel, a user with elevated permissions will be created and you will be sent an email containing the login credentials. The username will be chosen according to the operating system, for example “ubuntu” or “debian”.
You can now connect to your VPS via SSH with username and password. (SSH is a secure communication protocol. Find out more in our Getting Started with SSH article). You can access your server through a command line terminal (Linux or MAC) or through third-party software on Windows (we can recommend PuTTy).
Using PuTTy, for example, simply open the application and enter your server's hostname or IPv4 address to establish a connection. You will be prompted for your username and password and then you can proceed with the command line interface (CLI).
Once you have opened the terminal, type the following command to log into your VPS with the information provided in the email (username and IPv4 address):
ssh username@IPv4_of_your_VPS
Since you are now logged in with elevated privileges (a sudo user), you can enter commands to perform administrative tasks. It is recommendable to first change your password:
~$ sudo passwd
New password:
Retype new password:
passwd: password updated successfully
Note that passwords are not displayed. Next, switch to the “root” user and set your admin password:
~$ sudo su -
~# passwd
New password:
Retype new password:
passwd: password updated successfully
Enabling root logins
Connecting with the “root” user is disabled by default as a security measure. If you need to permit these connections, you can follow the steps below.
Warning: Only perform the following steps if you need the ability to SSH into your VPS with the root user. Allowing this connection reduces the security of your VPS.
Use a text editor such as vim or nano to edit this configuration file:
$ sudo vi /etc/ssh/sshd_config
Add the following line.
PermitRootLogin yes
Look for this line and make sure it is commented out:
#PermitRootLogin prohibit-password
Save the file and exit the editor. Then restart the SSH daemon.
$ systemctl restart sshd
This should be sufficient to apply the changes. Alternatively, reboot the VPS (~$ reboot
).
Restarting your VPS (current VPS range)
A reboot might become necessary in order to apply updated configurations or to fix an issue. Whenever feasible, perform a “soft reboot” via the command line:
reboot
However, you can carry out a “hard reboot” at any time in your OVHcloud Control Panel. From the Home
tab, click on ...
next to “Boot” in the Your VPS box, then click Reboot my VPS
and Confirm
the action in the popup window.
Installing or reinstalling your VPS
You can carry out any reinstallation directly in your Control Panel. From the Home
tab, look for “OS/Distribution” in the box Your VPS. Click on ...
and then on Reinstall my VPS
.
In the popup window, you will be asked to choose:
- an operating system from the drop-down list
- an SSH Key (optional)
Some proprietary operating systems or platforms such as Plesk or cPanel require licenses which generate additional fees. Licenses can be managed from the OVHcloud Control Panel: go to the Bare Metal Cloud
section, then click on Licenses
in the left-hand navigation.
In order to have a Windows operating system running on a VPS, it has to be selected in the order process. A VPS with another OS installed cannot be reinstalled with Windows in the described way.
A progress bar for the reinstallation will appear in your Control Panel - please note that installation can take up to 30 minutes.
First steps (older VPS range, ranges sold in 2020 and earlier)
Connecting to your VPS (for older ranges)
When you install (or reinstall) your VPS, you will be sent an email containing your password for root access. Root access lets you connect via SSH to your VPS. SSH is a secure communication protocol. You can access your server through a command terminal (Linux or MAC) or through third-party software on Windows (we can recommend PuTTy).
Using PuTTy for example, simply open the application and enter the servername or its IPv4 address to establish a connection. You will be prompted for username and password and then you can proceed with the command line interface (CLI).
Once you have opened the terminal, type the following command to log in to your VPS, replacing the text after the @ symbol with the information required (IPv4 address or VPS reference name):
ssh root@IPv4_of_your_VPS
Or:
ssh root@your_VPS_reference_name
Restarting your VPS (for older ranges)
A reboot might become necessary in order to apply updated configurations or to fix an issue. Whenever feasible, perform a “soft reboot” via the command line:
reboot
However, you can carry out a “hard reboot” at any time in your OVHcloud Control Panel. From the Home
tab, click on Reboot my VPS
, then click Confirm
in the popup window.
Installing or reinstalling your VPS (for older ranges)
You can carry out any reinstallation directly in your Control Panel. Simply click Reinstall my VPS
in the “Home” tab:
A window will open, and you will be asked to choose:
- your operating system from the drop-down list
- the language
- an SSH Key (optional)
Some proprietary operating systems or platforms such as Plesk or cPanel require licenses which generate additional fees. Licenses can be managed from the OVHcloud Control Panel: go to the Bare Metal Cloud
section, then click on Licenses
in the left-hand navigation.
In order to have a Windows operating system running on a VPS, it has to be selected in the order process. A VPS with another OS installed cannot be reinstalled with Windows in the described way.
A progress bar for the reinstallation will appear in your Control Panel - please note that installation can take up to 30 minutes.
Securing your VPS
As explained in the “Objective” section of this guide, you are the administrator of your VPS. As such, you are responsible for your data and its security. Please check out the following guides based on your OS to learn how to secure your VPS.
How to Secure Your SSH Connection in CentOS 7
How to Secure Your SSH Connection in Ubuntu 18.04
Attaching a domain
Making your VPS available on the web usually includes attaching a domain name to it via DNS. Your DNS provider will have information on how to configure your DNS records on their website.
Securing a domain with an SSL certificate
Once you have configured your VPS, you may want to secure your domain name and your website as well. This will require an SSL certificate, allowing the website to be accessed via https as opposed to http only.
You can manually install this SSL certificate directly on the VPS. Please refer to the official documentation of your VPS distribution.