I have:
Eclipse.ini:
-startup
plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.1.R36x_v20100810
-showsplash
org.eclipse.platform
--launcher.defaultAction
openFile
--launcher.XXMaxPermSize
512m
-vmargs
-Xms512m
-Xmx1024m
-Xmn256m
-XX:MaxPermSize=512m
-XX:GCTimeRatio=2
-XX:ParallelGCThreads=8
-XX:+UseParNewGC
-XX:MaxGCPauseMillis=2000
-XX:+DisableExplicitGC
-Dsun.lang.ClassLoader.allowArraySyntax=true
-Dweblogic.home=D:\Oracle\Middleware10.3.4\wlserver_10.3
-Dharvester.home=D:\Oracle\Middleware10.3.4\Oracle_OSB1\harvester
-Dosb.home=D:\Oracle\Middleware10.3.4\Oracle_OSB1
-Dosgi.bundlefile.limit=750
-Dosgi.nl=en_US
I want to increase the heap size, but when I increase -Xmx1024m
to -Xmx2048m
it says:
Failed to create the Java Virtual Machine.
Then again I introduced -vm
argument to my eclipse.ini as
-vm
D:\Java\jrockit-jdk1.6.0_26-R28.1.4-4.0.1\jre\bin\jrockit\jvm.dll
(before -vmargs
) it says:
Failed to load JNI shared library.
What to do? How to increase the Heap Size for Eclipse?
Contrary to your assertion, you have a 32-bit version of Eclipse. I can tell by the org.eclipse.equinox.launcher reference in your eclipse.ini file. A 64-bit eclipse would have this file named "...win32.x86_64..." instead of "win32.x86...".
Since Eclipse has native components, you have to use a 32-bit JVM with a 32-bit Eclipse. You are seeing "Failed to load JNI shared library" problem when trying to force the use of 64-bit JVM because Eclipse native components in your install are not compatible with a 64-bit JVM.
In terms of being able to increase the heap in your install... You are very unlikely to be able to increase the heap to 2048m. On startup, JVM tries to reserve a contiguous memory block based on the max heap size. The 32-bit address space is 4G total, but it is broken up by various system DLLs pinned into memory at various locations. The max contiguous memory will vary from system to system, but it is very unusual to find a contiguous 2048m block.
I am not 100% positive about this, but I heard that Jrockit does not have the contiguous memory requirement. If so, you may be able to solve your problem by switching to Jrockit like you are trying, but you need to install a 32-bit version of Jrockit.
Of course, an even better solution would be to move to a 64-bit version of Eclipse. It looks like your Eclipse install came from OSB installer. These are only available in 32-bit flavors, but I believe the OSB installer supports installing OSB plugins into an existing Eclipse install that contains Oracle Enterprise Pack for Eclipse (OEPE). OEPE has pre-built 64-bit Eclipse kits available, but you need to determine which version of Eclipse and OEPE the OSB plugins require (it will be one specific version).
Good luck.
UPDATE: Just remembered something else... Sometimes it is easier to run with higher Xmx settings if you use javaw.exe instead of jvm.dll as memory management is different between those two entry points. To try this, find the path to your 32-bit JVM's javaw.exe and specify it via -vm switch just like you are trying to specify an alternative jvm.dll in your question.