Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I downloaded the latest version of Eclipse, but I can not start it.

The error message I get is:

Failed to load the JNI shared library "C:\Program Files (x86)\Java\jdk1.6.0_20\bin..\jre\bin\client\jvm.dll".

How do I fix this?

I use 64-bit Windows, 32-bit JDK, and downloaded 64-bit Eclipse.

share|improve this question
    
That's strange. The jvm.dll should be in C:\Program Files (x86)\Java\jdk1.6.0_20\jre\bin\client\jvm.dll, not in C:\Program Files (x86)\Java\jdk1.6.0_20\bin\... – AndrejaKo Sep 8 '10 at 9:17
up vote 31 down vote accepted

This usually happens if you have a 32- vs. 64-bit mismatch between the installed JDK and Eclipse versions!

Your version of Eclipse is trying to access a 32-bit JDK (as indicated by C:\Program Files (x86)), but either fails because Eclipse is expecting a 64-bit JDK or because the 32-bit JDK is missing - consequently you'll need to make sure to match the Eclipse and JDK versions bit wise accordingly.

share|improve this answer
    
I use 64 bit Windows, 32 bit JDK, and downloaded 64 bit Eclipse. Now with 32 bit Eclipse it works better, thanks. – Jonas Sep 8 '10 at 16:54
    
@Jonas - I removed the erroneous assumptions about the installed versions, thanks for pointing this out by specifying your setup. – Steffen Opel Sep 8 '10 at 17:32

I had installed both JDK and Eclipse 64-bit versions, but had the same issue...

Finally I discovered that my %PATH% system variable didn't include the folder. Don't forget to change it to the correct folder where your JDK\bin is installed. Worked for me.

share|improve this answer
-startup
plugins/org.eclipse.equinox.launcher_1.1.1.R36x_v20101122_1400.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.2.R36x_v20101222
-product
org.eclipse.epp.package.java.product
--launcher.defaultAction
openFile
--launcher.XXMaxPermSize
256M
-showsplash
org.eclipse.platform
-vm
C:/Program Files/Java/jdk1.6.0_32/jre/bin
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xms40m
-Xmx512m

use eclipse and os both 64 bit or both 32 bit

share|improve this answer

On Windows 7 you have the chance to use symbolic links as under unix.

So with cmd (run as an admin), run the following: mklink /d jdk jdk-versionnr-etc you don't need to update your path, JAVA_JOME the next time you update Java !

share|improve this answer

I had a 64 bit Eclipse and 32 bit Java and had the same issue. After installing 64 bit Java and updating system path, no issues.

share|improve this answer

If you have downloaded 64-bit Eclipse and a 64-bit JDK/JRE, check the availablity of javaw.exe for 64-bit.

In my case it was in C:\Program Files\Java\jre6\bin

I have extracted Eclipse to the c:\eclipse folder; within that the eclipse.ini file is available. Replace the contents of that file with the following:

-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256M
-vm
C:\Program Files\Java\jre6\bin\javaw.exe
-framework
plugins\org.eclipse.osgi_3.4.3.R34x_v20081215-1030.jar
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Xmx700m
-XX:MaxPermSize=690M

Leave the new line in between the -vm flag and the value. It worked for me.

share|improve this answer
    
Thanks. All I did was copy the line" -vm C:\Program Files\Java\jre6\bin\javaw.exe" I left everything else the same. – Stopher87 Aug 4 '11 at 15:01

I was facing same issue even though I had 64-bit versions of both JDK and Eclipse. I found out that the JDK path was missing in eclipse.ini.

So I added following lines in eclipse.ini file:

-vm
C:\Program Files\Java\jdk1.7.0_45\jre\bin <this might be different on your machine>

This solved the problem! :-)

share|improve this answer

If eclipse is 64 bit , update Java in Path to C:\Program Files\Java\jre7

or else

check the Java location being referred by eclipse and copy the content C:\Program Files\Java\jre7 to eclipse jre location.

Reference - http://www.buggybread.com/2013/01/failed-to-load-jni-shared-library.html

share|improve this answer

1.Uninstall available jdk7.1 (It was 64 bit) 2. Downloaded and installed jdk7.1 32 bit. The jvm.dll will be in the follwing path: "C:\Program Files (x86)\Java\jdk1.7.0_75\jre\bin\client"

Hope it works.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .