I wanted to run a jar with the following command.
java -jar test.jar
What I need to add to the command so that I can get jre path info which it will be running against.
ANd also How can I force above jar to run against particilar jvm.
If I read the question correctly, you are trying to find out the location of the default JVM and how to change it. If this is correct, the answer depends on your operating system. Please add this information, and try to make the question clearer and more specific.