Forge Server Tools · every failure mode · guides
What Aikar's flags do, which ones still apply on modern Java, and the two settings that matter more than the whole rest of the list.
Before any flag list: the right Java version and a sane heap size account for more than every tuning flag combined.
-Xmx around 75% of physical RAM, and -Xms equal to it.
See how much RAM.A widely-copied G1GC tuning set aimed at one goal: avoid long garbage collection pauses, even at the cost of slightly more total GC work. A GC pause is a frozen server, so trading throughput for shorter pauses is the right trade for a game.
The ones doing the real work:
-XX:+UseG1GC — the collector the rest assumes. Default on modern
Java, so usually redundant now.-XX:MaxGCPauseMillis=200 — the target pause. This is the flag that
most directly reflects the goal.-XX:G1NewSizePercent / G1MaxNewSizePercent — a larger
young generation, because Minecraft allocates enormous numbers of
short-lived objects per tick.-XX:+ParallelRefProcEnabled — reference processing in parallel
rather than during the pause.-XX:+PerfDisableSharedMem — stops a stall when the JVM writes perf
data to a filesystem that happens to be slow.-Xmx.The honest version: most flag changes produce a difference you cannot feel, and it is very easy to convince yourself otherwise. Use Spark to record tick times before and after, and change one thing at a time. A plausible theory about performance is worth nothing against a measurement — the time a tool in this project took to run was once "fixed" by an obviously-correct change that moved the number by 0.00 seconds.
Forge Server Doctor performs the whole procedure above — reads the report, finds the real cause under the wrappers, skips the vanilla frames, and names the mod jar. 24 failure modes, each with its fix. The free edition covers the six most common startup failures.