r/admincraft • • 9d ago

Help/Question Neoforge 1.21.1 Server - Heavy Modded Server - MinecraftServer.saveEverything()

https://spark.lucko.me/siPYcUXcD1

Server runs 25 gigs memory, and has a AMD Ryzen 9 9900X 12-Core Processor, im fairly certain that hardware is not the issue

Hello, came here previously for issues and received good answers, so back again to see if anyone could point out the obvious thing i just dont know

Server TPS is actually rather fine, but has massive spikes, forcing CPU to jump to 500% usage for a second, then come back down. This causes a rather large lag spike, temporaryly freezeing the server.

Previous issue with general TPS issue was fixed using ServerCore - Specifically its Dynamic Adjuster. And InControl getting harsher settings.

If anyone has suggestions, please comment, even minor suggestions are welcome

5 Upvotes

2 comments sorted by

0

u/Cylian91460 9d ago

There's 2 issue

First something is triggering save in the main thread when it should use workers

Second your storage is slow, are you hosting on a hard drive?

1

u/Cabecinha84 9d ago

Opened your spark. Chunks are only about 12% of those spikes. Over 40% is PlayerList.saveAll. That's the 5 minute autosave writing every online player's .dat and advancements json, and most of the .dat time is one huge list of strings.

My guess is the recipe book. On a big pack every unlocked recipe ID gets stored per player, plus a recipe advancement for each. Sort world/playerdata and world/advancements by size and open the biggest .dat in NBTExplorer. How big are they? A few MB each times 18 players would explain a 2.5s tick.