This is an old revision of the document!
Table of Contents
Games - Minecraft - Create a Minecraft Server
NOTE: These instructions are for installing a basic vanilla Minecraft server without any add-ons or plugins.
Install Ubuntu Server
Install the Ubuntu OS as usual.
Update the packages
apt update apt upgrade
Install Apps
apt install tmux wget git most htop
Install Java
apt install openjdk-16-jdk
Create a User Account
adduser minecraft --disabled-login --disabled-password
NOTE: It is best to have a separate user account to avoid possible security vulnerabilities on the system.
- Simply press the Enter key to skip filling in the usual account information.
- No password is specified for this user.
- The account is only going to be accessible from the root account.
Switch to the new user
su - minecraft
Create a directory to hold the Minecraft server
mkdir ~/server && cd ~/server
Install the Minecraft server
Obtain the link for the Minecraft download
Visit the official Minecraft site, https://minecraft.net/download/server, and right-click on the download link and select Copy Link Location from the context menu.
Download the Minecraft Java file
wget download_link
NOTE: download_link is the link from the previous step.
Agree to the End User License Agreement
echo "eula=true" > eula.txt
NOTE: This creates a file named eula.txt.
- This tells the software that the Minecraft End User License Agreement is accepted.
- The terms and conditions can be viewed on the Minecraft website.
Start the Minecraft Server
tmux -s new minecraft java -jar server.jar
NOTE: Tmux is being used to allow detaching of the session.
- Enter help for a list of commands.
- To shut down your server, enter the command stop.
Enhance the Minecraft Server
For add-ons, mods and to personalize the Minecraft experience consult this official documentation: https://help.mojang.com/.
Connect to the Minecraft Server
Download the Minecraft client from the official Minecraft website.
Install and launch the client and sign in.