Start by reading the OutOfMemoryError type. Java heap fullness, local memory issue, and process terminating from hosting limit are not resolved in the same way.
Step by step
-
Get the actual error text at the end of the log. Distinguish between
Java heap space,unable to create native threadand137exit code on the panel. -
Compare the initial
-Xmxvalue and the panel memory limit. Leave space for memory used by Java and plugins outside of heap. -
If the heap is constantly growing over time, investigate the world, player load, and recent plugin changes where the issue occurs. Perform memory analysis in a controlled environment.
-
After a change, observe again at normal intensity. Check how process memory, heap and disk swap behave individually.
Keep in mind
Heap dump may contain player or configuration data. Sharing publicly.