Page 1 of 2

Java error

Posted: Thu Jan 12, 2012 12:19 pm
by arozumalski
I get the following error when trying to run OpenSim 2.4.0 on a Windows XP machine:

Required library failed to load. Check that the dynamic library osimJavaJNI is in your PATH
java.lang.UnsatisfiedLinkError: C:\OpenSim2.4.0\bin\osimJavaJNI.dll: Can't find dependent libraries.

Java is up to date.
I have unistalled and reinstalled OpenSim.
C:\OpenSim2.4.0\bin is included in the PATH environmental variable.
The file osimJavaJNI.dll does exist in this folder.

Any ideas of what might be going on here?

Re: Java error

Posted: Thu Jan 12, 2012 12:51 pm
by aymanh
Hi Adam,

Considering that we had the software installed on hundreds of machines without problem, I'd think the issue may have to do with your environment. Possible sources:
1. Windows is not patched up so there are some missing dlls from your machine that are needed to run the application. Solution: Windows update or if you have some other Visual Studio installed, use the proper installer for it (VS8Pro, VS9Pro, VS10Express are available the Pro versions are supposed to be self contained and be more robust on locating these dlls).
2. Path is too long. I've seen this on a couple of machines where the path is too long and so the batch file that launches opensim fails to append to the front of the path and hence the dlls are not found. Solution: make the path shorter if possible or set it from a command prompt and make sure it gets appended.

There are potentially other reasons I can think of but please try these two and let me know how it goes.

Good luck,
-Ayman

Re: Java error

Posted: Thu Jan 12, 2012 2:32 pm
by arozumalski
Thanks for the quick response, Ayman!
Because I work at a large institution, I am not allowed access to Windows Updates. However, the computer is scheduled to check for updates daily and install them if found.
I do not have Visual Studio on this machine.
I have shortened the Path variable so that it is shorter than on other machines where OpenSim is working but I still get the same error.
What are your other ideas?
Thanks!

Re: Java error

Posted: Thu Jan 12, 2012 2:58 pm
by aymanh
Adam,

Which installer did you use? Have you tried the one ending in VC8P? You'll need to have the right privileges to run the redistributable program on your machine as that program installs the missing dlls if any. You can invoke it manually from the install directory/bin/vcredist_x86.exe

Please let me know how that goes.

If you have the dependency walker you can open the osimJavaJNI.dll and see what errors you get and then we can track that down but I'd try the approach above first.

Good luck
-Ayman

Re: Java error

Posted: Mon Jan 16, 2012 11:30 am
by arozumalski
Ayman,
Installing the VC8P version worked. Thank you very much for your help!
Adam

Re: Java error

Posted: Mon Jun 18, 2012 7:14 pm
by dfgraham
As an addition to this conversation, I had the same error when installing on my new machine running windows 7, the problem was resolved when I installed vcredist_x86.exe which can be found in Tim Dorn's OpenSim Utilities.

Hope that helps

David

Re: Java error

Posted: Tue Jul 30, 2013 10:29 pm
by jmyron
Hey David,
You're solution worked.

Thanks,
Jits

Re: Java error

Posted: Wed Jul 31, 2013 9:41 am
by aymanh
Hi Jits,

What installer did you use and what problem did it exhibit? the redistributable vcredist_x86.exe is specific to the VisualStudio version used to build the distribution and is included in the bin directory of the install. If the one we ship didn't work and you had to go get it somewhere else then please let us know so we can fix the installer.

Thanks,
-Ayman

Re: Java error

Posted: Mon Dec 02, 2013 7:23 am
by madelinem
I also experienced this error with OpenSim 3.1 for 64bit Windows. Manually running C:\OpenSim 3.1\bin\vcredist_x64.exe fixed the problem.

Thanks!

Re: Java error

Posted: Tue Dec 10, 2013 1:55 pm
by daniela
Hi.Can you help me?
I have this error:

A java.lang.NullPointerException exception has occurred.

Click Show Details or see the messages.log file located in your C:\Documents and Settings\laughlin\Application Data\.opensim\2.0.0\var\log folder.

The details are as follows;

java.lang.NullPointerException
at org.opensim.view.pub.ViewDB.updateModelDisplay(ViewDB.java:1048)
at org.opensim.coordinateviewer.CoordinateViewerTopComponent.rebuild(CoordinateViewerTopComponent.java:579)
[catch] at org.opensim.coordinateviewer.Installer$1.run(Installer.java:23)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)

Thanks for the help,

Daniela Albuquerque