Tutorial - how to Create a Minecraft Server on a VPS

22 December, 2022

Tutorial - how to Create a Minecraft Server on a VPS

Minecraft is a very popular sandbox game. If you want to play multiplayer, it must be hosted on a server.

You can either rent a pre-built Minecraft server, or you can setup it yourself on a VPS server or dedicated server. This will lower the cost and allow you to have full control of your game instance.

This tutorial demonstrates how to launch a Minecraft Java Edition Server on an OVHcloud VPS, and then test its connectivity.

This guide will demonstrate how to use OVHcloud solutions with other tools. It will also describe the actions that should be taken in a particular context. You may need to modify the instructions to suit your particular situation.

If you have any difficulty performing these actions, please contact a specialist provider and/or talk to our community. More information can be found in the Go further section.

- A Virtual Private Server in OVHcloud - A GNU/Linux distribution installed to the server
- Administrative access (root), via SSH to your server
- An overview of GNU/Linux administration


This tutorial is based upon Minecraft Java Edition version "1.17" and OpenJDK version 16.0.1.

Step 1 - Prepare the server

First, set up your VPS to install Minecraft.
It is recommended that you order a new VPS, or reinstall an old one, from your OVHcloud Control Panel. This will allow you to use the most recent Ubuntu or Debian release. If you need help, please refer to our Getting Started guide.

Once the OS has been installed, connect to your VPS using SSH, as described in the Getting Started guide.

First, update the packages to the latest versions:

Run the following command to make sure all packages are installed.

Install the Java Package:

To prevent security holes on your system, create a user called "minecraft" to perform the server actions.

To skip filling out the usual account information, simply press the Enter key.

Now the user has been created. This user has no password. This is normal as the account can only be accessed via SSH when it is already connected to your user account.

Change to the new user:

The user "minecraft" must execute the following commands

Create a folder called server to complete the setup preparations.

Step 2: Install your Vanilla Minecraft server

A "Vanilla server" is an instance that does not require any plugins or add-ons. The game will be played exactly as it was designed by the developers.

First, copy/paste this link to download the server software. Right-click the download link on the official Minecraft website and select Copy Link Location in the context menu.

In your command line terminal, ensure that you are still in the server directory and use wget for the file download. Replace download_link by the URL from your clipboard

Before you can launch the server, you must agree to the End User License Agreement. Enter the following command to do this.

Now, a file called eula.txt can be found at the root of your server. It contains the line eula=true. This will inform the software that you have accepted the Minecraft EULA. We invite you to read the Minecraft Terms and Conditions.

Now you can start your server.

We installed the screen package during step 1. This allows you to open multiple sessions of the terminal (shell). We will launch Minecraft in a new session that runs in the background. Screen can be very useful because it allows you to launch multiple Minecraft servers at once.

We will first create a new shell called minecraft1:

The active terminal window will switch over to a new shell session. You can create multiple shells. List them with this command.

To remove the shell from your computer (and continue to run it), press Ctrl, followed by a, then then d on the keyboard.

Use this command to switch between shells:

You can also use Ctrl, followed by a, then then n to access

The following command will launch the Minecraft server from the minecraft1 shell. (Use ls if the filename is not correct.

Enter the command stop to shut down your server.

Step 3 - Connect to the server

Your server instance is now operational. Download the Minecraft client from Minecraft's official website to play the game.

Download and launch the client to your operating system. Sign in.

Next, enter the server name into the field Server Name and the IP address in the field server address.

By default, there is no port to specify.

Now your Vanilla Minecraft server has been installed on your VPS.

This installation guide is compatible with OVHcloud public cloud servers. instance. These services will give you better stability because the hardware is dedicated.


For add-ons, mods and to personalise your Minecraft experience, please consult this official documentation: https://help.mojang.com/

Join our community of users on https://community.ovh.com/en/

Did this guide help you?

Feel free to suggest improvements to this documentation.

Please share your feedback, regardless of whether it is about images, content or structure, so we can all improve it.

This form will not process support requests. This form cannot be used to submit support requests. Please use the "Create ticket" form.

We are grateful. We appreciate your feedback.