Minecraft is a game that has taken the world by storm. With millions of players worldwide, it is no surprise that many people are looking to create their own Minecraft server to play with friends or to create a community of players. Setting up a Minecraft server may seem like a daunting task, but with the right tools and guidance, it can be a simple and enjoyable experience.
In this article, we will provide you with a comprehensive guide on how to set up a Minecraft server from scratch. We will cover everything you need to know, from installing and configuring a Linux server to setting up your Minecraft server and making it accessible to others. We will also show you how to rent an already prepared server from GPORTAL, a popular Minecraft game server provider. Whether you are a seasoned server admin or a beginner, this ultimate guide will help you create the perfect Minecraft server for you and your friends. So, sit back, grab a cup of coffee, and let’s get started on this exciting journey of creating your very own Minecraft server.
Pros & Cons of Self-Hosting a Minecraft Server on your PC
Pros
- Customization: You have complete control over your server and can customize it to your liking, including choosing mods, plugins, and game modes.
- Performance: Depending on the hardware of your PC, you may be able to achieve better performance than a shared hosting server, as you don’t have to share resources with other users.
Cons
- Cost-effective: Hosting your own server on your PC can be very expensive if you run your PC 24/7 compared to just renting a game server.
- Security: Hosting a server on your PC can make it vulnerable to cyberattacks, and you may need to invest in security measures like firewalls and anti-virus software to protect your computer.
- Technical expertise: Setting up and maintaining a Minecraft server can be complex, and you may need to have technical expertise to manage it effectively.
- Resource usage: Running a server on your PC can consume a lot of resources like CPU, RAM, and bandwidth, which can slow down your computer and impact other applications you may be running.
- Reliability: Your server’s reliability is dependent on your internet connection and the stability of your PC. Any power outages, network issues, or hardware failures could result in downtime for your server.
Pros & Cons of Self-Hosting a Minecraft Server on a rented server
Self-hosting a Minecraft server can be a great option for those who want complete control over their server and want to customize it to their liking. However, it also has its pros and cons.
Pros
- Complete control: Self-hosting gives you complete control over your server. You can customize it to your liking, add plugins, and manage it however you want.
- Lower cost: Self-hosting can be less expensive than renting a server.
- No restrictions: When you self-host, there are no restrictions on the number of players or the amount of resources you can use. You can have as many players as you want, and you can allocate resources as needed.
Cons
- Technical knowledge required: Self-hosting requires some technical knowledge. You need to know how to install and configure a server, manage security, and troubleshoot any issues that may arise.
- Maintenance: With self-hosting, you are responsible for maintaining the server. This can be time-consuming and require regular updates and backups.
- Security risks: When you self-host, you are responsible for managing the security of your server. This includes setting up firewalls, managing user permissions, and keeping software up to date. Failure to properly secure your server can lead to security breaches and data loss.
- Limited support: When you rent a Minecraft server from a hosting provider, you have access to technical support. With self-hosting, you are on your own when it comes to troubleshooting issues.
Pros & Cons of Renting a Minecraft Server
Renting a Minecraft server is a popular option for those who want a hassle-free experience and do not want to deal with the technical details of self-hosting. However, it also has its pros and cons. Here are some of the main advantages and disadvantages of renting a Minecraft server:
Pros
- Easy setup: Renting a server is very easy to set up. You do not need any technical knowledge, and the hosting provider takes care of everything for you.
- Technical support: Hosting providers offer technical support, so if you run into any issues, you can get help quickly and easily.
- Scalability: Renting a server allows you to easily scale up or down as needed. If you need more resources or players, you can upgrade your package without any downtime.
- Security: Hosting providers manage server security, so you do not need to worry about managing firewalls or keeping software up to date.
Cons
- Cost: Renting a server can be more expensive than self-hosting, especially if you have a large number of players.
- Limited control: Renting a server limits your control over the server. You may not be able to install certain plugins or make certain changes to the server settings.
- Resource limitations: Hosting providers may limit the amount of resources you can use, such as RAM or CPU usage. This can limit the number of players you can have on the server or the amount of activity you can have.
- Downtime: Hosting providers may experience downtime, which can cause your server to be unavailable for periods of time.
Now that you know about the Pros & Cons of each of the hosting methods of a Minecraft Server, it’s up to you to decide. But no matter what you decide: In this article we will cover both methods. Let’s begin with self-hosting.
Self-hosting a Minecraft Server (manual)
This chapter is suitable for both installing a Minecraft Server on a rented Linux server as well as running it locally on a PC with a Linux-based operating system.
Before you can start with the actual installation of a Minecraft Server, you need to meet a few requirements first:
Requirements
- A server with a Linux-based operating system & enough resources (We recommend at least our VPS M SSD)
- SSH- & Root-Access to your Server
Installation of required packages
In order for your Minecraft Server to work at all, a few packages are required. In our example we use a Linux-Server with Debian 10 as the operating system. So, keep in mind that some commands may vary depending on your operating system.
Install the needed packages with the following command:
apt install screen wget –y
Installation of Java
Java is one of the key components when it comes to running your own Minecraft server. It’s also very important to install the right Java version for the right Minecraftversion. In the following table you will find different Minecraftversions and the corresponding Java version you need to install:
Minecraft Version | Required Java Version |
1.7.10 – 1.16.5 | Java 8 |
1.17.x | Java 16 |
1.18+ | Java 17 |
In our example I will setup a server running the latest version of Minecraft, which is as of today Minecraft 1.19.3. Therefore Java 17 is required.
In order to install Java 17, execute the following commands, command-after-command:
mkdir /usr/java
cd /usr/java
wget https://download.java.net/java/GA/jdk17.0.1/2a2082e5a09d4267845be086888add4f/12/GPL/openjdk-17.0.1_linux-x64_bin.tar.gz
tar xvf openjdk-17.0.1_linux-x64_bin.tar.gz
rm openjdk-17*.tar.gz
mv jdk-17*/ /usr/java
mv jdk-17* jdk-17
sudo update-alternatives --install /usr/bin/java java /usr/java/jdk-17/bin/java 20000
Pro-Tip: If you want to install a different Minecraft version later on and therefor need to install a different Java version, use this command to change between the active Java versions:
sudo update-alternatives --config java
This menu will pop up:
Here you can see every installed Java version. By typing in the corresponding number, you can change which version will be active (e.g. 3 for Java 8)
Downloading the Minecraft Server Files
Before we start with downloading the files we need, let’s quickly create a separate folder where our Minecraft instance will be running.
You can create this folder wherever you want, but I prefer to do it in the home directory. So, I will create a folder there with the following command:
mkdir /home/Minecraft
After the folder has been created, lets switch to it with this command:
cd /home/Minecraft
Now it’s time to download the actual Minecraft Server File. The server download for the newest Minecraft Major version can always be found here: https://www.minecraft.net/de-de/download/server
Now right-click “minecraft_server.1.19.3.jar” and select “Copy link address”
Pro-Tip: If you want to setup a server for a different/older version, just google “Minecraft [VERSION] server download” to download the corresponding jar-file.
To download the file directly to our server, we can use wget – the package we installed before. To do so type “wget” into your console and paste the link, you’ve copied from the Minecraft website, with a right-click and hit enter.
For our example the whole command would look like this:
wget https://piston-data.mojang.com/v1/objects/c9df48efed58511cdd0213c56b9013a7b5c9ac1f/server.jar
Create a Start Script
Now we need to create a script with which we can start our server. To do so, use this command to create the script:
nano start.sh
And paste in the following content:
screen -S Minecraft java -Xms512M -Xmx4G -jar server.jar
After you’ve pasted the content, save the file with [CTRL+O] and exit the editor with [CTRL+X].
Pro-Tip:
If necessary, please modify:
- Xms for the minimum amount of RAM you want to allocate
- Xmx for the maximum number of RAM you want to allocate
Also, lets accept the EULA (End User License Agreement) by creating a file called eula.txt with this command:
nano eula.txt
And paste in the following content:
eula=true
After you’ve pasted the content, save the file with [CTRL+O] and exit the editor with [CTRL+X].
In the last step we will make the script executable by using this command:
chmod +x start.sh
Start the Minecraft Server
Now it’s finally time to start our server. To do so, use this command:
./start.sh
Pro-Tip:
Because our Minecraft instance is running inside a screen-session the server will continue to run even if we close our console/shutdown the PC we used to connect to the remote server.
If you want to close the Minecraft-console (e.g. you want to do something else on your Linux server, use [CTRL+A]+D to close (detach) the console.
If you want to open it up (re-attach) again, use this command:
screen –rx
Congrats! Your Minecraft server is up and running. If this was too complex for you, but you still want to self-host your Minecraft server, we got you covered with our next self-hosting method!
Self-hosting a Minecraft Server (using a Script)
This method is suitable for everyone who wants to take advantages of self-hosting a Minecraft server and keeping full-control of the server, but found it too complicated to execute the steps above.
We will use “mcserver_installer” by realTM – an open–source, powerful and extensive Bash-Script to install Minecraft servers on your Linux server.
More information and the source-code of this project can be found on the official GitHub page here: https://github.com/officialrealTM/mcserver_installer
Prerequisites/Requirements
- A Linux server with a supported Linux distribution (Debian & Ubuntu) and enough resources (We recommend at least our VPS M SSD)
- Root & SSH Access to your Linux server
Download the script
In order to download the script, the git-package needs to be installed on your server. To install it use:
apt install git –y
Now download the script with this command:
git clone https://github.com/officialrealTM/mcserver_installer.git
Running the script
After downloading the script go into its directory with this command:
cd mcserver_installer
And execute the script with this command:
./mcserver_installer.sh
When starting the script for the first time, it wants to install some required packages. Hit “Yes” to continue.
This process can take a few moments to finish.
After the initial setup process, the script will ask you which type of Minecraft server you want to install. From now on this will be the menu you will get every time you start the script.
As you can see, this script can install Minecraft Vanilla, Forge, Spigot and Paper servers. In this case we will go with “Minecraft Vanilla” – so we hit enter to select it.
Now it prompts us to enter the exact Minecraft version we want to install on our server:
We will select the, as of today, newest version, which is 1.19.3
Pro-Tip: It’s important to enter the version number in the right format, otherwise it will result in an error. Also make sure to enter a supported Minecraft Version (From 1.7.x to 1.19+, no Snapshot-Versions)
The script automatically detects that in order to run a Minecraft 1.19.3 server, Java 17 is required and asks you if you want to install it:
Hit “Yes” to install it. This process will take a few moments to finish.
After the installation has finished, you can either select a pre-defined amount of RAM to allocate to your Minecraft server or set a custom amount.
Pro-Tip: If you don’t want to run anything on the server except the Minecraft server, you can allocate up to 75% of the Linux server’s RAM. In this example, our VPS M SSD has 16GB of RAM, so we could allocate a maximum of 12GB of RAM to the server. If you want to run other things on your Linux server besides the Minecraft server, we recommend you allocate no more than 50% of the RAM to the Minecraft server – so in our example, no more than 8GB.
After selecting the amount of RAM, your Minecraft server has been set up.
Your server has been saved in the displayed directory. To start it go to this directory. In our example use this command:
cd Servers/Minecraft-1.19.3
To start the server, use this command:
./start.sh
Congrats! Your Minecraft 1.19.3 server is up and running in less than 3 minutes!
If you want to learn more about the other features of the script and how to use them check out the official documentation of the script here.
Renting a Minecraft Server
If you don’t want to deal with all the configuration and just want to start playing with your friends right away, renting a Minecraft Server is a viable option. In this guide we will show you how to rent a Minecraft server at GPORTAL, a very big game server provider from Germany.
Create an Account
In order to create and manage your game servers at GPORTAL, a user account is required. If not done yet, create one at https://www.g-portal.com/de/register
Select a Server Plan:
After clicking on “Minecraft” on the left side under “Products” you can choose a server plan or create a custom configuration.
In this example, I will choose to create a custom configuration by clicking on the related button.
I will select “Minecraft Vanilla” in the top dropdown menu, select 2GB RAM with the slider and select 3 days as the duration.
For the available locations select a location which is as close to your location as possible for a good connection to the server.
Important: I chose the lowest settings for RAM and duration because this is only a test server, and I won’t play on it. If you want to learn more about how much RAM you need for what number of players/types of servers check out GPORTAL’s guide here.
Now click on “Continue” to continue with your Minecraft server order
Select Payment Method
GPORTAL offers a variety of payment methods (depending on your location) e.g. Creditcard, PayPal and more.
In this example I will pay with my balance – and click on “Order”
Activate your server
After clicking on “Order” this menu will pop up where you can choose if you want to activate your server now or later. Keep in mind: As soon as you hit “Activate Now” the duration-counter will start ticking.
Now click on “Go to the server configuration” to access your server’s dashboard:
Congrats! Your rented Minecraft server is up and running and you can start playing with your friends.
If you want to learn more about how to configure your Minecraft server at GPORTAL check out their Wiki here.
Conclusion
In conclusion, setting up a Minecraft server can be a fun and rewarding experience. Whether you choose to self-host on your pc or on remote server or rent an already prepared Minecraft server, this ultimate guide has provided you with a comprehensive overview of the process. We have covered everything from installing and configuring a Linux server to setting up a Minecraft on a server.
Self-hosting a Minecraft server on a VPS can give you complete control over your server and can be less expensive than renting a managed Minecraft server. However, it requires technical knowledge and can be time-consuming to maintain. It’s gets even harder when you try to do it on your own PC at home.
Renting a ready-to-go Minecrafta server can be easy and hassle-free, with technical support and scalability options. However, it can be more expensive and limit your control over the server.
Ultimately, the decision to self-host or rent a server depends on your needs and budget. Regardless of which option you choose, we hope that this ultimate guide has provided you with the knowledge and tools necessary to create the perfect Minecraft server for you and your friends.
So, grab your pickaxe, put on your helmet, and dive into the exciting world of Minecraft servers. With the help of this guide, you’ll be up and running in no time!