Finding the multiple JRE installed path in Linux OS

for my requirement on finding the JRE installaiton folder on windows and Linux machines , I can able to get it in windows but I am facing problem in getting the jre installed path from Linux machine. I am using Debian etch OS. Can anyone help me to find the installed path of JRE in Linux machine using a Java program. I need to find the multuiple JRE installed paths, i.e. my java program should find all the JRE installed paths and versions of the same.
Thanks in advance.
Edited by: VijayForumScreen on Jul 29, 2008 5:46 AM

As per the terminal prompt its ok...but i need the java concept to retrieve the versions and installed paths of the all JRE.
e.g;For current JRE we can get by,
System.out.println(System.getProperty("java.version"));
System.out.println(System.getProperty("java.home"));
Output:
1.5.0_10
/usr/lib/jvm/java-1.5.0-sun-1.5.0.10/jre
If i installed 1.3 and 1.4 also.,
How can i get installed paths and versions for all three 1.3,1.4 and 1.5 JRE's

Similar Messages

  • Multiple JREs installed - how to select correct one?

    Hi all
    I have multiple JREs installed on my computer, which I need to keep.
    I'm doing some development, and when I try to run the class, I get the following error:
    Exception in thread "main" java.lang.UnsupportedClassVersionError: HelloWorldApp
    (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)java -version shows:
    java version "1.3.1_01"
    Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01)
    Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)The reason I'm getting this error is because Eclipse is using the following JRE:
    C:\Program Files\Java\jre6\bin>java -version
    java version "1.6.0_17"
    Java(TM) SE Runtime Environment (build 1.6.0_17-b04)
    Java HotSpot(TM) Client VM (build 14.3-b01, mixed mode, sharing)My Path environment variable is:
    C:\Program Files\Java\jre6;C:\oracle\ora92\bin;C:\Program Files\Oracle\jre\1.3.1\bin;C:\Program Files\Oracle\jre\1.1.8\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files\Intel\DMIX;C:\Program Files\Gemalto\GACMy CLASSPATH environment variable is:
    C:\Program Files\Java\jre6;C:\Program Files\gemalto\gac\GATicket.jar;How do I force my Windows XP system to use the latest JRE installed?
    Thanks

    Thanks again.
    However, it appears the PATH variable may be a red herring.
    If I set the class path to exclude the jre6 directory, as follows:
    C:\oracle\ora92\bin;C:\Program Files\Oracle\jre\1.3.1\bin;C:\Program Files\Oracle\jre\1.1.8\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files\Intel\DMIX;C:\Program Files\Gemalto\GACThen the following error occurs:
    C:\Documents and Settings\Me\workspace\RegexTestProject\bin\regextest>java -
    version
    java version "1.3.1_01"
    Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01)
    Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)
    C:\Documents and Settings\Me\workspace\RegexTestProject\bin\regextest>dir
    Volume in drive C has no label.
    Volume Serial Number is 2806-C30D
    Directory of C:\Documents and Settings\Me\workspace\RegexTestProject\bin\re
    gextest
    03/09/2010  13:55    <DIR>          .
    03/09/2010  13:55    <DIR>          ..
    03/09/2010  13:56             1,707 RegexTestHarness.class
                   1 File(s)          1,707 bytes
                   2 Dir(s)  11,257,622,528 bytes free
    C:\Documents and Settings\Me\workspace\RegexTestProject\bin\regextest>java R
    egexTestHarness
    Exception in thread "main" java.lang.UnsupportedClassVersionError: RegexTestHarn
    ess (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)This is expected as the class was compiled using a later version of the JDK.
    However, if I update the PATH, and add the JRE6 entry to the path as follows:
    C:\Program Files\Java\jre6\bin;C:\oracle\ora92\bin;C:\Program Files\Oracle\jre\1.3.1\bin;C:\Program Files\Oracle\jre\1.1.8\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files\Intel\DMIX;C:\Program Files\Gemalto\GACI then get a class not found exception!!??
    C:\Documents and Settings\Me\workspace\RegexTestProject\bin\regextest>java -
    version
    java version "1.6.0_17"
    Java(TM) SE Runtime Environment (build 1.6.0_17-b04)
    Java HotSpot(TM) Client VM (build 14.3-b01, mixed mode, sharing)
    C:\Documents and Settings\Me\workspace\RegexTestProject\bin\regextest>dir
    Volume in drive C has no label.
    Volume Serial Number is 2806-C30D
    Directory of C:\Documents and Settings\Me\workspace\RegexTestProject\bin\re
    gextest
    03/09/2010  13:55    <DIR>          .
    03/09/2010  13:55    <DIR>          ..
    03/09/2010  13:56             1,707 RegexTestHarness.class
                   1 File(s)          1,707 bytes
                   2 Dir(s)  11,257,618,432 bytes free
    C:\Documents and Settings\Me\workspace\RegexTestProject\bin\regextest>java R
    egexTestHarness
    Exception in thread "main" java.lang.NoClassDefFoundError: RegexTestHarness (wro
    ng name: regextest/RegexTestHarness)
            at java.lang.ClassLoader.defineClass1(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$000(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)
    Could not find the main class: RegexTestHarness.  Program will exit.Below is the code of the class:
    package regextest;
    import java.io.Console;
    import java.util.regex.Pattern;
    import java.util.regex.Matcher;
    public class RegexTestHarness {
        public static void main(String[] args){
            Console console = System.console();
            if (console == null) {
                System.err.println("No console.");
                System.exit(1);
            while (true) {
                Pattern pattern =
                Pattern.compile(console.readLine("%nEnter your regex: "));
                Matcher matcher =
                pattern.matcher(console.readLine("Enter input string to search: "));
                boolean found = false;
                while (matcher.find()) {
                    console.format("I found the text \"%s\" starting at " +
                       "index %d and ending at index %d.%n",
                        matcher.group(), matcher.start(), matcher.end());
                    found = true;
                if(!found){
                    console.format("No match found.%n");
    }Based on the above, I think the path is set correctly, but I'm doing something else wrong.
    Thanks for you help so far. :-)

  • Cannot find the HTML browser installed on your system

    Guys forgive me if you have answered this before, I have
    tried a search of previous issues TNA.
    I have reloaded R/H 6 to my laptop (with full admin rights
    set against my user name) everything except works except generating
    in Microsoft HTML Help I get the following error when I click
    Finish: cannot find the HTML browser installed on your system
    Any ideas welcome. With thanks, J

    Hi JayRichard
    You might try the following.
    Inside RoboHelp HTML, click Tools > Options...
    Click the Tool Locations tab
    At the bottom of the dialog should be an area listing
    "Browser paths". You should see one for Internet Explorer and one
    for Netscape. Try clicking the little file folder icon to the right
    of one of them. (Whichever browser you are using)
    Navigate to and select the executable file for the browser.
    Mine for Internet Explorer says:
    D:\Program Files\...\iexplore.exe (The full path is
    D:\Program Files\Internet Explorer\iexplore.exe
    Dismiss the dialogs by clicking the Open and OK buttons until
    they are all gone.
    Keep us posted on whether this helps... Rick

  • It seems that many (if not all) of my files have been replaced by older versions. I kind find the multiple versions (listed in the Search as in the same dir) and restore them but this is strange. There is no chance that another user here has done a restor

    It seems that many (if not all) of my files have been replaced by older versions. I can find the multiple version including the most recent version using the Search, however, they show up in the same directory even though Finder only shows a single copy. I am able to save and then overwrite in order to restore but this is strange. There is no chance that another user here has done any sort of system restore action (at least intentionally).

    I can find the multiple version including the most recent version using the Search, however, they show up in the same directory even though Finder only shows a single copy.
    In a OS Extended (HFS) file system there is no way you can have two files with identical names in the same directory.
    Of course who knows what spotlight is thinking of most of the time when it does its stupid searches (get Find any File instead) and lists its results?  Are you sure it is listing the same directory or do you have a backup and it is finding it there and you aren't noticing it is two different volumes?
    You could also try reindixing the volume.  Add it to the Spotlight system preferences Privacy and then remove it.

  • BCT - how to find the difference between installed BCT and the newest BCT?

    Hi,
    How do I find the difference between installed BCT and the newest BCT?
    or find a description of the newest BCT?
    Thank you.
    - Gunnar

    Hi,
    Thank you for your answer.
    I am aware of the possibilities you mention.
    I am looking for a way to find the parts of the business content that has been modified since I installed our current version WITHOUT installing anything.
    That is for example:
    If F&R business content has been moved from 3.x technology to 7.0
    If there is changes to the F&R content at all
    -> if our current version of business content already contains the newest version of Business Content for F&R, then it is not a prerequirement to an F&R project that we update business content.
    The possibility to see that the only changes might be in the area of SAP HCM ...
    Thank you.
    - Gunnar

  • When we can find the multiple queries in view logn

    hi all
    wen can we find the multiple queries in view log
    thnks
    Sreedhar

    Hi,
    Is this what you are asking?
    http://gerardnico.com/wiki/dat/obiee/nqlogviewer
    Close your previous thread assigning points
    Regards,
    Srikanth

  • Why I can not find the 'dbca' file in any where (linux)

    Under $ORACLE_HOME/bin ,I cannot find the 'dbca 'file,why ?should I config any others?
    Before I install oracle on linux ,I only checked the following use the command "rpm -q gcc make binutils openmotif"
    so I only install
    'gcc-4.1.2.42.el5'
    'make-3.81-3.el5'
    'binutils-2.17.50.0.6-6.el5'
    'openmotif-2.3.0-0.5.el5'
    my oracle version is oracle -xe-univ-0.2.0.1-1.0.i386,
    linux is redhat enterprise linux 5 (64bit)
    thanks!
    Edited by: user12469990 on 2010-1-18 下午6:01

    What dbca file?
    The installation docs are at http://docs.oracle.com.
    Follow them if you wish to be successful and that means don't use unsupported versions of Linux.
    Also you can use these links for help:
    http://www.morganslibrary.org/reference/linux_oracle_inst10g.html
    http://www.morganslibrary.org/reference/linux_oracle_inst11g.html
    http://www.morganslibrary.org/reference/linux_oracle_inst11gR2.html

  • How to find the OBIEE report  (Catelogue) path from BI enabled excel sheet

    Dear All,
    I have an excel sheet where the data is coming from BI server. How can I find the BI report name and path from the excel sheet.
    Regards
    Mustafa

    Sorry Friends,
    May be I am not conveying the message properly.
    Let me try to do it again.
    I have an excel sheet which is created by somebody else and send me by mail.
    This excel sheet is having connectivity to the BI server and pulling data from BI.
    What I want to know is to get the BI report and view name from the excel sheet so that I can do some modification in the report.
    Please not the owner of the excel file is un-reachable.
    Let say I have uploaded the sample Excel in the following URL http://www.fileflyer.com/view/VSHtOA8.
    This excel file is pulling data from our BI Server
    Could anybody tell me the report path, name and view name from the excel file
    Regards
    Mustafa

  • Where do I find the file to install Adobe Premiere Elements 10 on Windows 7 64 bits?

    Hi there. I ran a little search on the forum for that subject but I couldn't find it. So, if it is a double post or something like that, I'm sorry, and please lead me to where it was already talked about.
    The thing is: I bought the downloadable bundle with Premiere Elements 10 and Photoshop Elements 10 and I have the links to download them on my account, no problem. I installed them both on my Windows XP last year and that was ok.
    Yesterday I upgraded my PC and now I have Windows 7 64 bits on. I could install Photoshop Elements just fine, but when I try to install Premiere Elements 10, the following error message appears.
    So, what do I do? I looked for it on my account again and there is no other file there, just the same file I used before on Windows XP and I'm trying to use now, just like with Photoshop Elements 10, but that worked just fine.
    And that leads to my question that is the name of this discusssion. Can someone help me? I live in Brazil and I didn't want to call phone support, and since I didn't find any free agent to call me on chat support, I decided to go here.
    I hope you guys can help me and thank you in advance.
    My best regards,
    Joao Jose Gois

    Hi Jeff, thanks for the reply.
    Unfortunately it didn't work, but I guess that you helped me to really find the issue here.
    I really have only one installer available to me, for both Photoshop Elements and for Premiere Elements. However they have a slight difference in the file name.
    On Photoshop, when I download the files, their names are just "Photoshoplements_10_LS15" and the extension. However, on Premiere, after the name of the program there is "win32" and only then we get to the extension file.
    So, I only have access to Win32 download. Even if I click on the "Alternate Download Method", I can only see two files: One that is the .7z file and the .exe, but both saying "win32" in the name.
    I still can't install it in here.
    Is there any mail that I can send to adobe support? When I go to Brazilian Adobe Online Store and click on Support, I'm always redirected to the '.com' website and I end up here.
    Once again, thank you all in advance for all the help or attention for this thread.
    Regards,
    Joao Jose Gois

  • Finding the length of a path

    hey,
    i'm using cs3 and i have a few simple paths (curves) and i'd like to know the length of these curves but i can't seem to find an option, or whatever, for that.
    thanks

    You mean the length as you travel along the curves?
    Can't be done I'm afraid, at least not very accurately.
    If it's really important you could try arranging a whole lot of little squares along the path so that they touch each other and then counting them. But the result won't be accurate unless the squares are very small.
    However, if you know how the curves are constructed geometrically you can sometimes calculate their lengths.
    For example if the curve is an arc of a circle and you know the angle it subtends as a proportion of 360 degrees then it's fairly easy to use pi to find the length of it.
    Circumference of a circle = pi x diameter.
    "As every skoolboy kno" (nigel molesworth)
    Ellipses are more of a bother and I don't know the formulas for sinus curves, parabolas and that sort of thing.

  • JNI (Java from C) -- multiple JREs installed, need to use non-default one

    Hello,
    I don't know how many Google/forum searches I must have tried -- I can't seem to find a solution to my problem.
    I am calling Java from C. We have two types of environments:
    (1) 1.3/1.4 mix, and
    (2) 1.4 only.
    The mixed environments are configured to use 1.3 by default. This configuration will not be changed. The original developer's code needs backported to the mixed environment, but it has been discovered that his Java code is not 1.3-compatible.
    Since the code is not compatible with 1.3, I need a way to bypass the default JRE setting and get JNI to start a 1.4 JVM. Is there a way to do this?
    Thank you for your help.

    My "solution" is a kludge. It attempts to compensate
    for what I thus far believe to be an apparent lack of
    functionality. I believe the functionality I
    described should exist in JNI so that little jewels
    like my "solution" are not needed. What I am doing
    is improper. Therefore, I respectfully disagree with
    you.Except that your OP suggested that if you could replace it with 1.4 then that would be suitable solution.
    So if that is a suitable solution and you can in fact modify the JNI code then that is a solution that meets all of your needs.
    Regardless however you will note that the "The Java Native Interface" book in chapter 7 provides a specific section which
    1. Specifically points out why you can't depend on a generic VM loading mechanism
    2. Provides a specific mechanism which is OS/Platform specific, for doing runtime loading of the VM presuming certain constraints are followed.

  • Error "The System cannot find the specified" when installing XI3.1 FP1.3

    Error "The System cannot find the specified" happened when installing XI3.1 FP1.3 to client machine, however the installation is OK to server.
    After the error, go to Control Panel -> Add or Remove Programs, and observe.
    BusinessObjects Enterprise XI 3.1 Client Tools is installed,
    but BusinessObjects Enterprise XI 3.1 Client Tools Japanese Language Pack is not.
    And Language Pack install log is not written.
    The same error happened when installing .net2.0.
    The installation for FP1.2 is OK.
    Would you tell me what reason probablely this issue is?
    Thanks.

    Hello Sarah,
    I recommend to post this query to the [BusinessObjects Enterprise Administration|BI Platform; forum.
    This forum is dedicated to topics related to administration and configuration of BusinessObjects Enterprise, BusinessObjects Edge, and Crystal Reports Server.
    It is monitored by qualified technicians and you will get a faster response there.
    Also, all BOE Administration queries remain in one place and thus can be easily searched in one place.
    Best regards,
    Falk

  • Where can I find the right doc for SunStudio For Linux ?

    I can find the docs for SunStudio here, http://docs.sun.com/app/docs/doc/819-5265/6n7c29ck9?a=view
    but it seems that it doesn't right on linux platform.
    #include <stdio.h>
    int main(void)
    #if defined(sun)
            printf("sun defined \n");
    #else
            printf("sun undefined \n");
    #endif
    #if defined(unix)
            printf("unix defined \n");
    #else
            printf("unix undefined \n");
    #endif
    #if defined(sparc)
            printf("sparc defined \n");
    #else
            printf("sparc undefined \n");
    #endif
    #if defined(i386)
            printf("i386 defined \n");
    #else
            printf("i386 undefined \n");
    #endif
    #if defined(__sun)
            printf("__sun defined \n");
    #else
            printf("__sun undefined \n");
    #endif
    #if defined(__unix)
            printf("__unix defined \n");
    #else
            printf("__unix undefined \n");
    #endif
    #if defined(__SUNPRO_C)
            printf("__SUNPRO_C defined \n");
    #else
            printf("__SUNPRO_C undefined \n");
    #endif
    #if defined(__sparc)
            printf("__sparc defined \n");
    #else
            printf("__sparc undefined \n");
    #endif
    #if defined(__i386)
            printf("__i386 defined \n");
    #else
            printf("__i386 undefined \n");
    #endif
    #if defined(__SVR4)
            printf("__SVR4 defined \n");
    #else
            printf("__SVR4 undefined \n");
    #endif
            return 0;
    }[luoyi@qpd06 test]$ suncc -o test test.c
    [luoyi@qpd06 test]$ ./test
    sun undefined
    unix defined
    sparc undefined
    i386 undefined
    __sun undefined
    __unix defined
    __SUNPRO_C defined
    __sparc undefined
    __i386 undefined
    __SVR4 undefined
    where can I found the correct docs for SunStudio For Linux ?

    You can refer to cc man pages. Here is about predefinitions:
    Predefinitions:unix
    sparc (SPARC)
    i386 (x86)
    sun
    The above are not predefined in -Xc mode.
    These predefinitions are valid in all modes:
    __BUILTIN_VA_ARG_INCR
    __SUNPRO_C=0x590
    __SVR4(SPARC)
    __SunOS(Solaris)
    __SunOS_OSN.N(Solaris)
    __amd64(x86 with-m64)
    __gnu__linux(linux)
    __i386(x86)
    __linux(linux)
    __linux__(linux)
    __sparc(SPARC)
    __sparcv9(with-m64)
    __sun(Solaris)
    __unix
    __�uname -s�_�uname -r�
    __x86_64(x86)
    linux(x86,linux)
    The following is predefined in -Xa and -Xt modes only:
    __RESTRICT
    The compiler also predefines the object-like macro
    __PRAGMA_REDEFINE_EXTNAME,
    to indicate the pragma will be recognized.
    ...

  • HT1338 I purchased mountain lion from the app store and I can find the download to install it?

    I just bought Mountain Lion online and it started to download to my computer.  I walked away and I can't find the download or the screen to see if it finished downloading from the internet yet?

    It downloads to your Applications folder.

  • Im trying to download itunes and my computer will not run the itunes64 setup...where can i find the 32 bit install

    im trying to download itunes on my pc...it says it can't run itunessetup64...how do i find the 32 bit version

    it says it can't run itunessetup64
    What's the precise text of that message, please?

Maybe you are looking for

  • String to array convertion problem

    Hi, I am reading this from url which returns js array. But when i m trying to covert int to array i stuck. string str="[{"CompanyCode":"17023928","LastTradedPrice":"15,878.68","Volume": "0","PercentageDiff":"1.35","FiftyTwoWeekHigh":"21,206.77","Fift

  • Scripts - How to define a different dimension

    Hi, I have  data for certain members called "concepto", these data is going to be stored in the dimension TIME but only for year. What i want to do is take this data by year and spread it to each month of the year. But also, the members of the dimens

  • Mouse not going away

    I'm having issues with the mouse icon not going away on a quicktime movie I'm running for an artwork at a museum. I have a computer set to start up at a specific time and then a applescript to run on start up that opens the movie, loops it, and sets

  • How to delete excessive spaces for a string??

    like String s="i am a new guy" how to make it to "i am a new guy" ?? i've tried trim() seems it does work for this case thanks

  • IPhone URL Caching

    I have an application that downloads a lot of data and stores it locally for off-line use. I thought I could use NSURLCache for this. Just create a disk cache in a local directory and be done. Alas, it doesn't work... When I create the cache, it does