Yes, let's make a Minecraft server (Oracle Linux + Spigot + Geyser)

I tried to set up Bedrock Server in the previous post, but when I thought about it, I thought that Mac people could not participate, so I switched to the Java version server and decided to cover the Bedrock version with Geyser. did.

I was thinking about it casually for fun, but it became magnificent ...


environment

Linux preparation

There are many ways to install the OS on the web, so I will omit it.

Let's do it around.

JDK installation

# dnf -y install java-11-openjdk-headless
$ java --version
openjdk 11.0.9.1 2020-11-04 LTS
OpenJDK Runtime Environment 18.9 (build 11.0.9.1+1-LTS)
OpenJDK 64-Bit Server VM 18.9 (build 11.0.9.1+1-LTS, mixed mode, sharing)

Install Spigot

Let's create a server execution user first, as we will need it later.

# mkdir /opt/minecraft
# groupadd minecraft
# useradd --system --shell /bin/bash --home /opt/minecraft -g minecraft minecraft
# chown minecraft:minecraft /opt/minecraft

Build by referring to Spigot Wiki.

Install the application required for build

# dnf -y install git wget

Build Spigot

# su - minecraft
$ mkdir survival
$ cd survival
$ wget https://hub.spigotmc.org/jenkins/job/BuildTools/lastSuccessfulBuild/artifact/target/BuildTools.jar
$ java -jar BuildTools.jar

Agree with EULA

$ java -jar spigot-1.16.4.jar
$ vi eula.txt

Change eula = false to eula = true

eula.txt


:
eula=true

Match memory usage to server specs

# vi /opt/minecraft/survival/server.conf

server.conf


MCMINMEM=512M
MCMAXMEM=7168M

I wondered if it was ready to start at least for the time being.

Next, create a startup script by referring to Tutorials/Server startup script.

Install screen to run Spigot inside a virtual terminal

# dnf -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
# dnf -y install screen

Download systemd script

# wget -O /etc/systemd/system/[email protected] https://raw.githubusercontent.com/agowa338/MinecraftSystemdUnit/master/minecraft%40.service

RHEL8 series seems to have to change the permissions of/run/screen

# vi /etc/systemd/system/[email protected]

[email protected]


  :
# Uncomment this to fix screen on RHEL 8
ExecStartPre=+/bin/sh -c 'chmod 777 /run/screen'
  :

Autorun settings

# systemctl enable minecraft@survival

I will start it for the time being

# systemctl enable minecraft@survival
# systemctl stop minecraft@survival

Installation of Geyser / Floodgate

Select the Download button of GeyserMC site and download "Geyser-Spigot.jar" from "Latest successful build artifacts" on the linked page.

# su - minecraft
$ cd /opt/minecraft/survival/plugins/
$ wget https://ci.opencollab.dev//job/GeyserMC/job/Geyser/job/master/lastSuccessfulBuild/artifact/bootstrap/spigot/target/Geyser-Spigot.jar

Select the Download link of Geyser's Floodgate wiki and download "floodgate-bukkit.jar" from "Latest successful build artifacts" on the linked page.

# su - minecraft
$ cd /opt/minecraft/survival/plugins/
$ wget https://ci.opencollab.dev/job/GeyserMC/job/Floodgate/job/master/lastSuccessfulBuild/artifact/bukkit/target/floodgate-bukkit.jar

Restart Spigot

# systemctl restart minecraft@survival

Allow Bedrock users to connect with only an Xbox Live account

# vi /opt/minecraft/survival/plugins/Geyser-Spigot/config.yml

config.yml


  :
  auth-type: floodgate
  :

Change Bedrock user name prefix (* Does not work well with some plugins, so change to ASCII characters)

# vi /opt/minecraft/survival/plugins/floodgate-bukkit/config.yml

config.yml


  :
username-prefix: "BE_"

  :

Restart Spigot

# systemctl restart minecraft@survival

I haven't confirmed the operation of the Java version yet, but I wonder if it works like this !?

Recommended Posts

Yes, let's make a Minecraft server (Oracle Linux + Spigot + Geyser)
[Part 1] Let's set up a Minecraft server on Linux
Set up a Minecraft resource (Spigot) server via docker (2)
[Part 2] Let's build a web server on EC2 Linux
Set up a Minecraft resource (Spigot) server via docker
Let's make a Discord Bot.
Let's make a rock-paper-scissors game
Let's make a remote rumba [Software]
Let's make a GUI with python.
Let's make a spot sale service 2
Let's make a breakout with wxPython
Let's make a spot sale service 1
Run a Linux server on GCP
Let's make a graph with python! !!
Let's make a supercomputer with xCAT
Let's make a spot sale service 3
Let's make a shiritori game with Python
Build a simple WebDAV server on Linux
Make Unity Accelerator a service on Linux
Let's make a voice slowly with Python
Let's make a simple language with PLY 1
Build a Samba server on Arch Linux
Make a Yes No Popup with Kivy
Let's make a multilingual site using flask-babel
Let's make a web framework with Python! (1)
Let's make a tic-tac-toe AI with Pylearn 2
Let's make a combination calculation in Python
Let's make a Twitter Bot with Python!
Let's make a web framework with Python! (2)
Let's make a Backend plugin for Errbot