Massive and often lag spikes
R3Ked opened this issue ยท 6 comments
Modpack version:
2.9.1
Description:
After the game has been open for a while, the game starts experiencing large and frequent lag spikes. The only way to fix it is by completely restarting the game.
Steps to reproduce:
- Play the game for a while.
Expected behavior:
It doesn't lag.
Additional context:
I want to post my PC specs for additional info, but don't know how.
What info do I need in particular?
Default settings, I think gives you a 4GB maximum heap when DJ2 works best with 8GB. Go to your curseforge settings, and you have two options:
- Bump that maximum up to 8GB.
- Ignore it, and enabled the G1GC garbage collector by using these settings as additional arguments:
-XX:+UseG1GC -XX:+UnlockExperimentalVMOptions -XX:G1NewSizePercent=20 -XX:G1MaxNewSizePercent=60 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=32M
but whenever you open the Minecraft launcher from Curseforge, you have to go to the additional settings and remove the first three settings since they have priority and will turn off the G1GC garbage collector.
If that doesn't help, it does help to know just how much RAM you actually have.
Havvy has a lot of helpful information there.
In addition to his comment, you have to consider the fact that any FTB modpack is making Minecraft do a ton of things and Minecraft is JAVA. There is a lot of garbage collection to be had and done and Java doesn't excel excel at that. At some point it WILL need rebooted.
I have a pretty powerful rig and I still have to reboot after ~6 hours no matter what settings I use. It's just the nature of the beast.