Linux Game Servers

A quick guide on installing various game servers on Debian. As I write more guides for installing different game servers, this page may be split up into multiple pages.

Minecraft Server

  1. Install Java JRE Headless
sudo apt install default-jre-headless
  1. Create a new directory for the Minecraft server
mkdir -p ~/games/minecraft
cd ~/games/minecraft
  1. Download latest Minecraft server .jar file from, and save it to the ~/games/minecraft directory.

  2. Make systemd service directory (as minecraft user) and make a new service file:

mkdir -p ~/.config/systemd/user
nano ~/.config/systemd/user/minecraft.service

Contents of file ~/.config/systemd/user/minecraft.service:

Description=Minecraft Server

ExecStart=java -Xms1G -Xmx2G -jar server.jar

  1. Start and enable service
systemctl --user daemon-reload
systemctl --user start minecraft
systemctl --user enable minecraft
  1. Open port 25565/tcp in firewall to allow others to connect to the server
sudo firewall-cmd --permanent --zone=public --add-port=25565/tcp 
  1. Launch Minecraft on your computer and connect to the server

BeamMP Server

  1. Install BeamMP dependencies
sudo apt install liblua5.3-0 libssl3 curl dtach
  1. Create game server folder
mkdir -p ~/games/beammp
cd ~/games/beammp
  1. Download BeamMP from GitHub.

Note: At the time of writing, there is no Debian 12 binary. Instead, use the Ubuntu 22.04 binary which appears to work fine.

wget -O beammp-server

# make the binary executable
chmod +x beammp-server
  1. Configure BeamMP using the directions on the BeamMP Wiki.

  2. Create systemd service file at ~/.config/systemd/user/beammp.service. Contents are below.

Description=BeamMP Server

ExecStart=dtach -n /tmp/beammp ./beammp-server


Start and optionally enable service

systemctl --user daemon-reload
systemctl --user start beammp
systemctl --user enable beammp
  1. Open port UDP and TCP port 30814, the port the BeamMP server listens on
sudo firewall-cmd --permanent --zone=public --add-port=30814/tcp --add-port=30814/udp

If you need to use the BeamMP server console, run the following command:

dtach -a /tmp/beammp

You can detach from BeamMP console by hitting Ctrl + \. If you accidentally kill the server, it will automatically restart in 5 seconds.