“Error occurred during initialization of VM; Could not reserve enough space for object heap” using -Xmx3G

user1212731 picture user1212731 · Feb 16, 2012 · Viewed 587.1k times · Source

First of all, I have a box with 8gb of ram, so I doubt total memory is the issue. This application is running fine on machines with 6gb or less.

I am trying to reserve 3GB of space using -Xmx3G under "VM Arguments" in Run Configurations in Eclipse.

Every time I try to reserve more than 1500mb, I get this error: “Error occurred during initialization of VM; Could not reserve enough space for object heap” using -Xmx3G

What is going on here?

Answer

Laurent picture Laurent · Feb 16, 2012

Could it be that you're using a 32-bit jvm on that machine?