Possible CPS limiter?
VanillaChan6571 opened this issue · 5 comments
Hello there,
So I have an issue where when I pregen the world it starts around 40 CPS.. slowly over 20 minutes it will reach 100+ CPS which sounds awesome then after a bit.. then the server stalls the cpu to 100% or 0% making to CPS go to 0.1.. which I call this a hard crash cause you have to force end task using task manager… I was thinking if there was a way to set a limit on the CPS? Seems for me 80 CPS is stable enough since it hangs around 70-80% cpu usage.
only way I bypass this is using a macro to force end task the server around every 25 minutes to continue chunk loading without the 0.1 - 1.0 CPS “Crash” and no… after it “hard crashes” the server slowly starts to lock up my pc by slowing making my mouse lag and other programs stop…
Specs:
Ryzen 9 3900X
32 GB of Ram (Allocating 16)
M.2 (4000 read and writes speeds about-ish)
Running [Fabric]
The exact question asked here is already covered by #4 (however not explicitly mentioned). In practice though I have found almost no circumstances where people actually need to limit cps on a task. CPU usage is generally very low per world due to other constraints on generation, and given you have a 3900X you should be having zero issues.
Running for a while at higher cps numbers and then dropping to zero is something commonly seen with servers that run out of memory. I would take a look at your memory usage first and figure out if there is something there causing an issue (such as a mod with a memory leak).
Please join the Discord server if you would like some help troubleshooting.
Well memory isn’t the issue. It reaches 20gb before doing this when I have 32.
A server using 20GB of memory is fairly unusual. Are you using proper startup flags, etc?
My flags are
java -Xms8096M -Xmx16384M -jar fabric-server-launch.jar nogui
I know there are better flags than this. If you have any suggestions let me know.
Just wanted to say that there are definitely scenarios in which a CPS limiter would be beneficial over an online players check. I for example run my chunk generations on my main desktop as it's much faster than my actual server. However, this means I cannot do much else for about 10 hrs. Limiting CPS to free up CPU usage for other apps outside of the minecraft server would solve this.