I'm running a Minecraft server on a computer with 16GB of RAM and a 64 bit Java, which is fully updated. My friend and I are the only people who are ever on the server. Yesterday, while exploring (negative 4-5K blocks away from spawn), the server starts lagging (my friend's screen showed that I wasn't moving when I actually was), then crashes. I assumed this meant the server had run out of memory and my friend and I disconnected & rejoined, then went back to 0,0. I didn't find it worth it to give the server more memory than the 1024MB it had at that point, so I let it be and everything went fine.
Today, on the beginning of an exploring mission (about 500 blocks from spawn [in the opposite direction as last time]), our (me and my friend's) boat started jittering and we were unable to move. Then the server crashed. If you'd like the crash report, please ask. I won't put it here because it's pretty long, but the crash report said “Watching Server java.lang.Error”. I assumed the server simply has run out of memory, so I allotted 2048MB to the server and restarted it. The server ran well - until I joined, at which point it crashed, with the following error:
---- Minecraft Crash Report ---- // I feel sad now :( Time: 12/25/18 5:30 PM Description: Exception in server tick loop java.lang.OutOfMemoryError: Java heap space at java.util.ArrayList.<init>(Unknown Source) at com.google.common.collect.Lists.newArrayListWithCapacity(Lists.java:190) at he.a(SourceFile:66) at gy.a(SourceFile:437) at gy.a(SourceFile:81) at gy.a(SourceFile:437) at gy.a(SourceFile:81) at hi.a(SourceFile:119) at hi.a(SourceFile:84) at hi.a(SourceFile:80) at bnv.a(SourceFile:104) at bnv.a(SourceFile:88) at bnv.a(SourceFile:136) at tc.a(SourceFile:102) at tk.<init>(SourceFile:43) at tl.c(SourceFile:172) at tl.a(SourceFile:203) at vp.a(SourceFile:273) at vp.c(SourceFile:342) at vp.a(SourceFile:166) at ue.b(SourceFile:113) at ue.Y_(SourceFile:65) at hw.a(SourceFile:238) at ub.c(SourceFile:171) at net.minecraft.server.MinecraftServer.b(SourceFile:773) at so.b(SourceFile:360) at net.minecraft.server.MinecraftServer.a(SourceFile:681) at net.minecraft.server.MinecraftServer.run(SourceFile:584) at java.lang.Thread.run(Unknown Source) A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- System Details -- Details: Minecraft Version: 1.13.2 Operating System: Windows 10 (amd64) version 10.0 Java Version: 1.8.0_191, Oracle Corporation Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation Memory: 1888248192 bytes (1800 MB) / 2038431744 bytes (1944 MB) up to 2038431744 bytes (1944 MB) JVM Flags: 2 total; -Xmx2048M -Xms2048M Profiler Position: N/A (disabled) Player Count: 1 / 20; [tf['TheFlamingCrab'/395, l='world', x=237.28, y=62.07, z=-641.02]] Data Packs: vanilla Is Modded: Unknown (can't tell) Type: Dedicated Server (map_server.txt)
I researched the error messages from both crash reports and have allotted 3G RAM to Minecraft and 4G to Java, and have tried running the server with 1024MB, 1G, 2G, and the default server size (bypassing batch file) and have received the same crash report each time, so I'm fairly sure the problem isn't with the RAM. When I try to join the server, the minecraft loading screen gets all the way to "loading terrain", then the server crashes at the time where I would normally join the game. Minecraft says either "server closed" or "java.lang.StackoverflowError". I researched this for about an hour and haven't gotten any answers, so I posted here. Thank you! (If you'd like to know any additional information please ask, I might have left things out).