How to see which JVM an executable Jar is using?
The project uses a dll which has to be copied to JVM_HOME/bin directory. From the IDE the application works fine (the dll is copied in JAVA_HOME/jre/bin) but when I try to run the application directly, the dll is not found.
- It is not PATH env variable.
- Running it with double click results in "dll not found", but when calling with java -jar myJar.jar the application works fine.
In the Windows task manager (Ctrl+Shift+Esc), you can open "View" -> "Select columns..." -> "Image path name". There are other nice options there, too, such as "Command Line" which also shows command line arguments.
Or you can use Process Explorer, where you can double-click a process to see image path, command line arguments, and much more.