Skip to content

Lesson 3 of 9 · 23m

Process Management, Updates, and Change Control

Run Minecraft as a managed service with controlled restarts, remote console access, staged updates, and a rollback path instead of a fragile terminal session.

A surprising number of "server outages" are actually screen sessions. Someone's SSH connection drops, the process dies, and the community learns that production depended on one laptop staying awake. Minecraft is a long-running stateful service; run it like one.

Use the service manager, not a terminal habit

A minimal systemd unit gives you startup, restart policy, logging, and dependency control:

[Unit]
Description=Paper Minecraft server
After=network-online.target
[Service]
Type=simple
User=minecraft
WorkingDirectory=/opt/minecraft/main
ExecStart=/usr/bin/java -Xms4G -Xmx4G -jar paper.jar nogui
Restart=on-failure
RestartSec=10
[Install]
WantedBy=multi-user.target

RCON is powerful and easy to misuse

RCON enables controlled commands without attaching to the Java console:

enable-rcon=true
rcon.port=25575
rcon.password=<long random secret>

Bind it to localhost or a private management network. Tools such as mcrcon can then coordinate saves, broadcasts, and graceful shutdowns:

mcrcon -H 127.0.0.1 -P 25575 -p "$RCON_PASSWORD"   'say Restarting in five minutes for maintenance' 'save-all flush'

Never expose RCON to the public internet. The protocol is effectively remote administration, and password brute force against it is an old sport.

Updates deserve a rehearsal

A serious update pipeline is simple:

1. Snapshot world/config/plugin state.
2. Stage the same jar/plugin/config set and test critical gameplay flows.
3. Apply during scheduled maintenance.
4. Keep the previous bundle ready to restore.

The exact artifacts matter. "Paper latest plus whatever plugins were in the folder" is not a version. Record the jar build, plugin jar names, config snapshot, and Java version together.

Crash loops are configuration failures too

If a bad plugin update prevents startup, automatic restart can hide the problem behind endless boot attempts. Read logs/latest.log and crash reports before deleting things. Rate-limit intervention: restore the known-good bundle first, then investigate in staging.

Field notes

  • stop from the console is safer than killing Java because worlds need a clean save flush.
  • Never run the server as root; a plugin vulnerability should not become host root by default.
  • Restarting automatically after failure is good; restarting automatically during world corruption can multiply damage.
  • Backups, permissions, and RCON secrets are part of the same operational boundary.

Was this lesson helpful?

Sign in to rate