I got JNI Exception: failed to create the Java VM

Bug #574951 reported by Jeremy
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
SikuliX
Won't Fix
Undecided
Unassigned

Bug Description

I just upgraded to 0.10 and now Sikuli doesn't want to start.
I got and error:

JNI Exception: failed to create the Java VM
Reason: not enough memory.

I have enough memory (almost 2Go free).

I have other application running java, like Java PS3 Media Server and it works perfectly ..
I'm on Windows XP

Revision history for this message
Jeremy (j0k3r) wrote :
description: updated
Revision history for this message
Tsung-Hsiang Chang (vgod) wrote :

Can you try running the Sikuli-IDE.bat instead of the default Sikuli-IDE.exe?

Revision history for this message
sagdude (rajanikanth-gmail) wrote :

Running Sikuli-IDE.bat seems to work but it is just giving the old gui interface (I also installed this on my Mac and it has a very useful GUI). The windows GUI is unlike the one I see on the Mac.

Thanks,
Raj

Revision history for this message
Tsung-Hsiang Chang (vgod) wrote :

Please completely uninstall the old Sikuli 0.9 and then reinstall the 0.10.

Revision history for this message
Jeremy (j0k3r) wrote : Re: [Bug 574951] Re: I got JNI Exception: failed to create the Java VM

I did it but I still have the same problem.

Jeremy

On Tue, May 4, 2010 at 8:52 PM, Tsung-Hsiang Chang <email address hidden> wrote:

> Please completely uninstall the old Sikuli 0.9 and then reinstall the
> 0.10.
>
> --
> I got JNI Exception: failed to create the Java VM
> https://bugs.launchpad.net/bugs/574951
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in Sikuli: New
>
> Bug description:
> I just upgraded to 0.10 and now Sikuli doesn't want to start.
> I got and error:
>
> JNI Exception: failed to create the Java VM
> Reason: not enough memory.
>
> I have enough memory (almost 2Go free).
>
> I have other application running java, like Java PS3 Media Server and it
> works perfectly ..
> I'm on Windows XP
>
>
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/sikuli/+bug/574951/+subscribe
>

Revision history for this message
Jeremy (j0k3r) wrote :

I did it but I still have the same problem (and btw I don't have tested the .bat for the moment)

Revision history for this message
Tsung-Hsiang Chang (vgod) wrote :

Sikuli allocates 256M from JVM as its default heap size. I am not sure why it said not enough memory given you have 2GB.
You can try to modify the Sikuli-IDE.bat and change -Xms256M to a smaller value, maybe 128M or 64M.

Revision history for this message
Jeremy (j0k3r) wrote :

Well, the good news is that Sikuli-IDE.bat works well (without any
modification).
But the .exe still failed.

On Tue, May 4, 2010 at 9:38 PM, Tsung-Hsiang Chang <email address hidden> wrote:

> Sikuli allocates 256M from JVM as its default heap size. I am not sure why
> it said not enough memory given you have 2GB.
> You can try to modify the Sikuli-IDE.bat and change -Xms256M to a smaller
> value, maybe 128M or 64M.
>
> --
> I got JNI Exception: failed to create the Java VM
> https://bugs.launchpad.net/bugs/574951
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in Sikuli: New
>
> Bug description:
> I just upgraded to 0.10 and now Sikuli doesn't want to start.
> I got and error:
>
> JNI Exception: failed to create the Java VM
> Reason: not enough memory.
>
> I have enough memory (almost 2Go free).
>
> I have other application running java, like Java PS3 Media Server and it
> works perfectly ..
> I'm on Windows XP
>
>
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/sikuli/+bug/574951/+subscribe
>

Revision history for this message
jesperfjoelner@hotmail.com (jesperfjoelner) wrote :

I'm getting this error but cannont get it running using the .bat file.
I'm on XP 1gb ram.

Revision history for this message
Cody Precord (cprecord) wrote :

I get the same error about the JNI exception when running the EXE.

When I run the bat script from the command line I get the following traceback

C:\Program Files\Sikuli>Sikuli-IDE.bat
Exception in thread "main" java.lang.UnsupportedClassVersionError: edu/mit/csail
/uid/SikuliIDE (Unsupported major.minor version 50.0)
        at java.lang.ClassLoader.defineClass0(Native Method)
        at java.lang.ClassLoader.defineClass(Unknown Source)
        at java.security.SecureClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.defineClass(Unknown Source)
        at java.net.URLClassLoader.access$100(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClassInternal(Unknown Source)

Running JRE 1.6 update 20 (which is the latest AFAIK)

Revision history for this message
Cody Precord (cprecord) wrote :

Posted too soon,

It appears that my system had the wrong version of java on the path first so it was picking up an earlier one. Modifying the batch script to explicitly point to the 1.6 runtimes allowed the program to start without issue.

Revision history for this message
balebond (balebond) wrote :

Same issue. Also on WinXp. But the .bat file does work.

Revision history for this message
Tsung-Hsiang Chang (vgod) wrote :

This should be fixed in 0.10.1

Changed in sikuli:
status: New → Fix Committed
RaiMan (raimund-hocke)
Changed in sikuli:
status: Fix Committed → New
RaiMan (raimund-hocke)
Changed in sikuli:
status: New → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.