0
votes

I am using a computer withe following specification: OS-Windows7 professional Installed Memory(RAM) :8Gb System Type: 64 bit Operating System JVM: Java version 8 update 91(jre1.8.0_91) 64 bit version

java version "1.8.0_91" Java(TM) SE Runtime Environment (build 1.8.0_91-b15) Java HotSpot(TM) 64-Bit Server VM (build 25.91-b15, mixed mode)

For using one desktop application I need large JVM memory allocation. With the above specification I can set the JVM at maximum 1.5gb(1536mb) using -Xmx command. If I am increasing the value above 1.5 GB getting the following error: "The JVM could not be started.The main method may have thrown out an exception."

Please let me know how can I allocate more memory to th e JVM.

2

2 Answers

1
votes

The 1.5 GB limit means you are most likely using the Windows XP/32-bit version. When this question has come up before the OP has been sure they were using the 64-bit version but on investigation found they were not.

I suggest making sure there is only one version of Java installed, the 64-bit version you want to use.

-1
votes

In my opinion the best way of detecting your problem is to use JProfiler, it can detects if you're having a problem inside your vm and can monitor the status, it's simple to use and give a lot of debug. I saw at some articles that sometimes increasing too much the memory cause an error like this but I don't have a clue, try to look this too, hope it helps.