Out of Memory Issue (OOM Kill)

Why does the server crash without any error message and what is an OOM Killer?

4 min read
#errors#ram#memory#oom#crashing#crash

The Out Of Memory (OOM) Killer is a dreaded process in the Linux system kernel. It monitors how much memory is consumed by all processes on the server. If the server's RAM is completely exhausted and no space is returned, the system would collapse and need a hard restart.

Instead of crashing, however, the OOM Killer steps in and finds out which program is taking up the most memory. It unceremoniously kills it to free up memory. In the panel, you will then usually find the message Server Marked as Offline: Out of Memory.

Why is this happening on my server?

  • You purchased too small of a RAM allocation for what you are doing (e.g., running a modpack with 300 mods on a 4GB server).
  • A Memory Leak occurred on the server - the program contains a bug causing it to take more and more memory indefinitely (and not letting Java's Garbage Collector do its job), until it consumes it all.
  • Generating the entire world in Minecraft all at once at huge speeds clogged the memory allocator.

What to do about it?

Change startup flags. In the Startup tab of your MC server, you will find optimized Java arguments (so-called Aikar's Flags). If you don't have them active, turn them on. They manage Java much more nimbly.

Delete unnecessary plugins and unsupported outdated modifications.

Upgrade your plan: For Minecraft hosting, simply perform an Upgrade of your package to assign more GBs of RAM.

If you run a giant map and your servers start crashing despite full RAM capacity, you need to pre-generate your entire chunk world, for example using the great Chunky plugin, which handles generation, thereby solving the vast majority of OOM crashes upon player connections.

Didn't find what you were looking for? Contact us.