Could not reserve enough space for object heap: the fix

The JVM asked for more memory than the plan can give it, almost always because a modpack hard-codes -Xmx. Clear the JVM arg and restart.

A Could not reserve enough space for object heap error means the JVM asked the operating system for a heap of a certain size, and the operating system said no. On Hostd, this happens when something inside the pack has set -Xmx to a value larger than the RAM your plan actually has.

Why this differs from "Java heap space"

OutOfMemoryError: Java heap space is the JVM running out of room while it is already running. Could not reserve enough space for object heap is the JVM failing to start because it cannot get the room it asked for in the first place. They feel similar; the fix is not the same.

The usual cause: a modpack with a hard-coded -Xmx

Forge and NeoForge packs ship a file called user_jvm_args.txt in the server root. Most packs leave it empty and let the launcher pick. Some hard-code a memory flag like -Xmx8G because that is what the pack author expected on a self-hosted box. If your plan is Modded (6 GB), the JVM tries to grab 8 GB, fails to reserve it, and the server never finishes booting.

user_jvm_args.txt, jvm_args.txt, unix_args.txt, run.sh and the related launcher files are managed by Hostd; the Files page will not let you edit them directly. That is intentional, because the only thing those files can do on a kernel-locked plan is break your boot. The fix lives elsewhere:

  • First, try re-installing the pack version. Open Dashboard → your server → Modpack and pick the pack again. Some pack updates drop the bad -Xmx value in a later release.
  • If a fresh install still ships the bad value, open a support ticket from Dashboard → Support and we will sanitise the JVM args file on our side. We typically clear it within an hour.

If the underlying problem is that the pack genuinely needs more memory than your plan offers, the fix is a tier upgrade rather than a JVM args change; see Allocating more RAM.

Where to go next

Last updated 2026-05-23. Notice a mistake? Tell us.

Cookies