Default Installation Of JDK (SDK)?

Can anyone give me a list of default installtion dir of JDK or SDK for windows, linux, and other platforms? I need to find tools.jar in JDK, but using java.home doesn't always work because the user could be using the JRE, in which case java.home will point to the JRE dir, not JDK.
Any help appreciated,
CoolAsIce

I don't think my original query was understood. I want your default installation of the JDK. Perhaps giving you my code will make you understand my intentions better:
import java.lang.reflect.*;
import java.io.*;
import java.net.*;
public class Compile
     private static Class mainClass = null;
     private static Method compileMethod = null;
     static
          try
               File toolsJar = null;
               File[] possibleLocations = new File[]
                    new File(new File(System.getProperty("java.home")).getParent(), "lib/tools.jar"),
                    new File("C:/Program Files/Java/jdk1.5.0_02/lib/tools.jar"),
                    new File("C:/j2sdk1.4.2_08/lib/tools.jar")
               for(int i=0; i<possibleLocations.length; i++)
                    if(possibleLocations.exists())
                         toolsJar = possibleLocations[i];
                         break;
               if(toolsJar != null)
                    mainClass = new URLClassLoader(new URL[]{toolsJar.toURL()}).loadClass("com.sun.tools.javac.Main");
                    compileMethod = mainClass.getMethod("compile", new Class[]{String[].class, PrintWriter.class});
          catch(Throwable t)
               //t.printStackTrace();
     public static void main(String[] args)throws Throwable
          System.out.println(compile(new File(args.length>0 ? args[0] : "Test.java")));
     public static String compile(File file)
          if(mainClass == null)
               throw new RuntimeException("tools.jar cannot be found!");
          try
               //invoke compile() method of Main.
               StringWriter sw = new StringWriter();
               PrintWriter pw = new PrintWriter(sw, true);
               Object[] arguments = new Object[]{new String[]{"-g:none", file.getAbsolutePath()}, pw};
               compileMethod.invoke(mainClass.newInstance(), arguments);
               pw.close();
               sw.close();
               return sw.toString();
          catch(Throwable t)
               return null;
What I need is more files for possibleLocations. Using java.home may not work because if the application is running under JRE, java.home will return the location of the JRE installation dir and tools.jar is not included in the JRE.
Best regards,
CoolAsIce

Similar Messages

  • Set JDK/SDK in Forte For Java 3.x

    Need to change from the current SDK/JDK setting in FFJ 3.x to 1.4.1_01
    Running Windows 2000.... default is JDK 1.3.1_03 in /usr/j2se
    How to do this???
    Thanks...

    I guess i did not clearly state the question...
    How does one change the default JDK/SDK in Forte 3, in this case change the default from 1.3.1 (initial install at /usr/j2se) to 1.4.1 (installed in /usr/j4se) ???
    Thanks...

  • Error OUI-25031 - default installation

    All day Im trying to install Oracle 10g Release 2 (10.2) for Solaris 10 (x86).
    Each time it finishes with error: OUI-25031.
    Its going to be just a default installation. I did it many times ago but never had this problem.
    The log file is telling nothing to me. It complains about Enterprise Manager Grid which I dont wont to install.
    Does anyone know what is the problem with it ?

    I have downloaded it on MAY previous year.
    I believe the link is this, as the size of the file is exactly this same: http://www.oracle.com/technetwork/database/10202solx86soft-089512.html
    Although I need to correct entry on my above post: file size on the UFS partition is: 681,090,961 bytes
    The document I refer to is: database\doc\relnotes.102\b15696.pdf (inside of the 10202_database_solx86.zip)
    Here is last 50 lines on installActions2011-01-08_09-56-02PM.log
    # An error report file has been saved as hs_err_pid6915.log.
    # Please refer to the file for further information.
    Command = /oracle/product/10.2.0/db_2/jdk/jre//bin/java has failed
    INFO: Configuration assistant "Oracle Net Configuration Assistant" failed
    *** Starting OUICA ***
    Oracle Home set to /oracle/product/10.2.0/db_2
    Configuration directory is set to /oracle/product/10.2.0/db_2/cfgtoollogs. All xml files under the directory will be processed
    INFO: The "/oracle/product/10.2.0/db_2/cfgtoollogs/configToolFailedCommands" script contains all commands that failed, were skipped or were cancelled. This file may be used to run these configuration assistants outside of OUI. Note that you may have to update this script with passwords (if any) before executing the same.
    INFO: Created a new file /oracle/product/10.2.0/db_2/cfgtoollogs/configToolFailedCommands
    INFO: Since the option is to overwrite the existing /oracle/product/10.2.0/db_2/cfgtoollogs/configToolFailedCommands file, backing it up
    INFO: The backed up file name is /oracle/product/10.2.0/db_2/cfgtoollogs/configToolFailedCommands.bak
    SEVERE: OUI-25031:Some of the configuration assistants failed. It is strongly recommended that you retry the configuration assistants at this time. Not successfully running any "Recommended" assistants means your system will not be correctly configured.
    1. Check the Details panel on the Configuration Assistant Screen to see the errors resulting in the failures.
    2. Fix the errors causing these failures.
    3. Select the failed assistants and click the 'Retry' button to retry them.
    INFO: User Selected: Yes/OK
    INFO: --------------------------------------
    INFO: The "/oracle/product/10.2.0/db_2/cfgtoollogs/configToolFailedCommands" script contains all commands that failed, were skipped or were cancelled. This file may be used to run these configuration assistants outside of OUI. Note that you may have to update this script with passwords (if any) before executing the same.
    INFO: The "/oracle/product/10.2.0/db_2/cfgtoollogs/configToolAllCommands" script contains all commands to be executed by the configuration assistants. This file may be used to run the configuration assistants outside of OUI. Note that you may have to update this script with passwords (if any) before executing the same.
    INFO: Since the option is to overwrite the existing /oracle/product/10.2.0/db_2/cfgtoollogs/configToolFailedCommands file, backing it up
    INFO: The backed up file name is /oracle/product/10.2.0/db_2/cfgtoollogs/configToolFailedCommands.bak.1
    SEVERE: OUI-25029:One or more "Recommended" configuration assistants have not completed successfully. Not successfully running any "Recommended" assistant means your system will not be correctly configured.
    INFO: User Selected: Yes/OK
    WARNING: Do you really want to exit?
    INFO: User Selected: Yes/OK
    INFO: The OUICA command is launched from /oracle/product/10.2.0/db_2/oui/bin/ouica.sh.
    WARNING:
    The following configuration scripts need to be executed as the "root" user.
    #!/bin/sh
    #Root script to run
    /oracle/product/10.2.0/db_2/root.sh
    To execute the configuration scripts:
        1. Open a terminal window
        2. Log in as "root"
        3. Run the scripts
        4. Return to this window and click "OK" to continue
    *** Starting OUICA ***
    Oracle Home set to /oracle/product/10.2.0/db_2
    Configuration directory is set to /oracle/product/10.2.0/db_2/cfgtoollogs. All xml files under the directory will be processedEdited by: user639256 on Jan 9, 2011 4:06 AM
    Edited by: user639256 on Jan 9, 2011 4:09 AM

  • JRE, JDK, SDK, IDE, J2????

    What is the disctinction between all these acronyms and when would they come in handy?
    JRE
    JDK
    SDK
    IDE
    Java2 versus JDK1.4 (what's the difference)

    JRE = Java Runtime Environment. Let's you run java apps/applets by interpreting the compiled java code supplied to you.
    JDK/SDK = Java Development Kit/Software Development Kit = One in the same...has both the JRE and tools (compiler, etc) to actually compile your own java code.
    IDE = Integrated Development Environment - Usually consists of an editor, project manager, graphical development tools to speed up development of code. This is not necessarily java - there are IDE's for C/C++, etc....
    Java2 - Post java 1.1 version of java ... components usually start with a J...like JPanel, JButton, JList. A layer built over the original AWT (abstract window toolkit) that was java 1.1. Java 2 is not supported by most browsers by default without the plugin (the JRE)...Netscape 6 has it tho it's buggy.
    JDK 1.4 is the latest version of Java2.

  • Default Installation on LVM is not working

    New Thread (Default installation of LVM not working):
    First I did everything exactly as the LVM guide tells me. Then I continued with the Installation Guide.  No extra options, no change from defaults. When I try to boot it, it fails.
    I tried downgrading to 2.02.103-1. No result.
    Old Thread (when I did not know that LVM was at fault):
    Current state:
    EDIT5: OK I have boiled it down to LVM. When I copied all files from etcvol to /etc in root it continued booting until it hit mounting /home... I have no idea what the §$%&/ is wrong.
    Everything that is not root and should get mounted by fstab from LVM dies o.O
    Even stranger: After I removed homevol and swapvol from fstab i get stuck at
    A start job is running for dev-sdb4.device
    I did a "proof of concept" installation just now and it worked out of the box.
    Parameters of the "proof of concept" installation:
    /dev/sda5 ext4 /
    /dev/sda4 EFI /boot
    Rest is default installation guide
    Gummiboot:
    title Arch Linux
    linux /vmlinuz-linux
    initrd /initramfs-linux.img
    options root=/dev/sda5 rw
    Changed Parameters of the broken installation:
    /dev/sda3 LVM on LUKS
    Partitions
    /dev/mapper/MyStorage-rootvol ext4 /
    /dev/sda4 EFI /boot
    /dev/mapper/MyStorage-swapvol swap
    /dev/mapper/MyStorage-homevol ext4 /home
    title Arch Linux (Encrypted)
    linux /initramfs-linux.img
    options initrd=/initramfs-linux.img cryptdevice=/dev/sda3:MyStorage root=UUID=$UUIDofRoot rw
    I added the HOOKS
    HOOKS="... encrypt lvm2 keymap ... filesystems ... shutdown ..."
    Fstab
    # /etc/fstab: static file system information
    # <file system> <dir> <type> <options> <dump> <pass>
    # UUID=767d41f7-afb5-4a9f-a39b-604c830654e7
    /dev/mapper/MyStorage-rootvol / ext4 rw,relatime,space_cache 0 0
    # UUID=6e00082a-4fc4-47a5-9e80-e2330428d2fe
    /dev/mapper/MyStorage-etcvol /etc ext4 rw,relatime,space_cache 0 0
    # UUID=ce066cf1-230a-48b4-b7a8-2635ef39a881
    /dev/mapper/MyStorage-homevol /home ext4 rw,relatime,space_cache 0 0
    # UUID=0C88-FA2A
    /dev/sdb4 /boot vfat rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro 0 2
    # UUID=9369aa55-d055-4fab-98ef-ccc97b3f3e05
    /dev/mapper/MyStorage-swapvol none swap defaults 0 0
    So what goes wrong? I can't provide the exact logs as the journal persistency module dies in this case. If you know a way to get the actual files please tell me.
    Everything works fine down to "Reached target Local File Systems"
    He runs some isEmpty checks on tmpfiles.d directories which some succeed and /etc/tmpfiles.d and /usr/local/lib/tmpfiles.d fail
    systemd-tmpfiles --create --remove --exclude-prefix=/dev gets forked
    journald gets killed by systemctl
    systemd-tmpfile SIGCHILDs and dies
    systemd-udevd gets notified and changes from start to running
    udevd-control.socket gets changes to running
    system-tmpfiles-setup exits with failure
    Failed to start Recreate Volatile Files and Directories
    systemd-update-utmp gets forked
    accepts connection on private bus
    10 times dbus request: org.freedesktop.dbus.local.disconnect() on /org/freedesktop/dbus/local
    SIGCHILD from systemctl belonged to systemd-journal-flush.service
    Failed to start Trigger Flushing of Journal to Persistent Storage
    more dbus request: org.freedesktop.dbus.local.disconnect() on /org/freedesktop/dbus/local
    systemd-update- from systemd-update-utmp SIGCHILDs and dies
    Failed to start Update UTMP about System Reboot/Shutdown
    starts system initialization sysinit.target -> active
    starts dbus.socket to listeing
    starts sockets.target to active
    systemd-tmpfiles-clean.timer gets started by monotonic timer to cleanup
    dbus-daemon gets forked
    dbus.socket from listening to running
    systemd-logind gets forked
    Failed to start D-Bus System Message Bus
    Failed to start Login Service
    I had a look at higher debug levels, but they all just showed systemd starting something which either failed or in the case of D-Bus died soon after.
    When I broke into init, I could see the volumes which contained what they were supposed to contain.
    Except that nothing really interesting. I noticed a complaint that the AHCI driver should be replaced against a specialized one. But I don't think thats the problem.
    Thank you for your help!
    Last edited by GNA (2014-01-15 21:44:01)

    Removed the fsck filehook.
    posted the fstab.
    Boot logs will follow shortly. I just have to figure out how to get them in file form when the journal does not contain anything.
    EDIT: OK I have no idea how to get my own boot logs sad but true. ill just try to add as much context as I can see but I can't possibly write all of this down by hand.
    EDIT2: Ah no wonder when flushing of journal to persistent storage fails
    EDIT3: Ill just start decreasing the complexity one by one. And as it is so easy ill start with btrfs.
    EDIT4: Changing btrfs to ext4 did not change anything.
    EDIT5: OK I have boiled it down to LVM. When I copied all files from etcvol to /etc in root it continued booting until it hit mounting /home... I have no idea what the §$%&/ is wrong.
    Everything that is not root and should get mounted by fstab from LVM dies o.O
    Even stranger: After I removed homevol and swapvol from fstab i get stuck at
    A start job is running for dev-sdb4.device
    EDIT6: Today I tried to make a "failsafe" system with lvm and luks. Turns out it is not failsafe.
    First I did everything exactly as the LVM on LUKS guide tells me. Then I continued with the Installation Guide.  No extra options, no change from defaults. The result is the very same I currently have.
    EDIT7: Now that I think about it; There was something strange during pvcreate /dev/mapper/lvm. It complained: "/dev/sdc: open failed: No medium found" which is strange as there was never a /dev/sdc to begin with.
    I'll try to install on a pure LVM partition without crypto.
    EDIT8: OK pure install only LVM is also broken.
    Last edited by GNA (2014-01-15 20:46:49)

  • Installation of RFC SDK

    Hello,
             As part of the effort to install BO integration for SAP, i have come across installation of RFC SDK as a prerequisite. I have downloaded the RFC SDK from the market palce (7.00 unicode for Windows 64 bit). But i have been reading up on the internet that RFC SDK can be installed as an add on component while installing SAP GUI.  I tried doing this using both, SAP GUI 7.10 (compilation 2) and SAP GUI 7.20 but can't find this component for selection. Am i missing something?
    On the other hand, i have the SAR file downloaded. I have already installed SAP GUI on the Business objects server. Do i install the RFC SDK on the Buisness Objects host (server)? I have unpacked the RFC SDK SAR file but am not sure, which directory / subdirectory to put it under.
    How do i go about this?
    Regards,
    Prashant
    Edited by: Prashant Pasala on Jul 5, 2011 5:30 PM

    Hello Ingo,
                      For Windows Installation, the document only mentions on page 43 that the RFC SDK needs to be downloaded and installed but nothing else. i have put the file librfc32.dll in the system32 folder as directed. I have put the Java connector files in their respective directories tough.
    i have used Java connector 2.1.10 64 bit X86  on a windows server 2008 (AMD Opetron). The directory for BO is Programfiles X86.
    I went ahead and installed BO integration kit (without RFC SDK files though). The installation went well. But after that when i start infoview, and click on Document list it comes up with the error
    The requested resource (/PartnerPlatformService/actionAuthFilter.do) is not available
    In CMC i can now see SAP in the Authentication tab but when i try to open it i get the same error as above. I have read on an SAP note that for this error re deploying the WAR files on Tomcat works. Is that right?
    Thinking again, can i still place the RFC SDK files in the proper directories now? but i still have no clue where to put them (directories).  Am i missing something from the document?
    Regards,
    Prashant

  • Workflow Server is installed with default installation of 10gr2 EE?

    Hi Guys,
    i listen many people that workflow engine is embedded from onward 8i and as we install 10g it's also install but i didn't find it in 10g Enterprise Edition.finally i install it from oracle 10g companion CD and configure it.any one can told me what it's my mistake that i cant find it or its not present in default installation and when we need we install it from companion CD.
    Regards,
    Shakeel Haider Khan

    ppls seem to forget that using open source platforms has some shortcomings as well,dont get me wrong its just that i would like to remind all users including myself wot time is it...meaning ...
    "Ninety days ago, Red Hat invested in the future of open source in the enterprise by
    acquiring JBoss," said Tim Yeaton, Senior Vice President of Enterprise Solutions, Red
    Hat. "Today, we reach one of our first milestones as customers, developers and partners
    can now tangibly benefit from the new JBoss channel offerings and the integrated, tested
    Red Hat Application Stack." source (http://jboss.com/)for further enquiries we might soon find ourselves on endless subscribsion bases.lets have fun

  • Modify default installation path of WindowsApps

    Modify default installation path of WindowsApps        
    First explain, I am a Chinese Windows user, my English fighting is only 5(very poor).Then I will try to use some simple English to tell you my problem.
    I use the method used in windows8 to modify default installation path of WindowsApps,but defeated.
    Why I want to modify default installation path of WindowsApps?
    Because when I installed software that is suitable for the traditional model, my C disc had only 10GB space.
    I think Win8.1 is perfect.And I like the traditional mode and Metro interface.(I heard Win9 can’t use two modes at the same time,but I think simultaneous use of two modes the operation is very nice.)
    The method used in windows8:
    First,Enter WinPE,create a file that is the mirror image of WindowsApps in D disc.
    Then,Enter Win8.1,make User get thechanges to the “Appx” folder under theregistry.
    Last,Amended registry master key of “packageRoot”as “D:/WindowsApps”
    This operation can be completed in Win8,but default in Win8.1.
    So,could you tell me how to modify default installation path of WindowsApps?
    If it’s impossible ,I hope Microsoft team could solve it.

    In my opinion it's a bad idea to change this, as most software is set to install on drive C: and not all of it may be using the proper CSIDL system calls to get the locations. 
    You can be sure the majority of testing is done with applications installing in the system default location on C:.
    A much better idea is to save a few Yuan and buy a much larger SSD for the system drive, then use the default drive C: locations for the operating system and installed programs.
    -Noel
    Detailed how-to in my eBooks:  
    Configure The Windows 7 "To Work" Options
    Configure The Windows 8 "To Work" Options

  • Default installation location

    Hello! I am installing the Oracle Database and Query Tool Express Edition for the first time. I have Windows 7 64-bit Ultimate Edition. I was merely wondering why the default installation location is C:\ rather than C:\Program Files\ or C:\Program Files (x86)\. If I change the location from the default, will this affect the software in any way (i.e. will the program have trouble finding certain files)? Is there any real reason to install it to C:\?

    Hi;
    Hello! I am installing the Oracle Database and Query Tool Express Edition for the first time. I have Windows 7 64-bit Ultimate Edition. I was merely wondering why the default installation location is C:\ rather than C:\Program Files\ or C:\Program Files (x86)\. If I change the location from the default, will this affect the software in any way (i.e. will the program have trouble finding certain files)? Is there any real reason to install it to C:\?You can change location but i stongly suggest do not use space when you are using different name
    Example:
    Use D:\My_Database\xxx
    Do not use D:\My Database\xxx
    Regard
    Helios

  • JDK & SDK

    Ok JDK is for Java development and SDK is for software development? What is the difference? I googled SDK and JDK and that is what it said anyway. Then another site said SDK is a new version of JDK, I knew i could only get the right answer here. Before i forget what about JRE and JVM? JRE is what you need to run java programs right? Does JRE run on the java virtual machine (JVM)? Why dont they make it one thing if thats the way it is? Like the JRM is a combination of JVM & JRE?
    So if i read correct i need JRE to run java programs does JRE already have a JVM included?

    JDK and SDK are the same.
    For version 1.4.x term SDK is used.
    http://java.sun.com/j2se/1.4.2/download.html
    SDK includes JRE. JRE is required for running Java applications
    For 1.5 and later JDK is used.
    http://java.sun.com/javase/downloads/index_jdk5.jsp
    http://java.sun.com/javase/downloads/index.jsp
    JDK includes the JRE.
    JDeveloper includes the JDK/SDK.
    http://wiki.answers.com/Q/What_is_difference_between_JVM_and_JRE
    http://java.sun.com/developer/onlineTraining/new2java/programming/learn/unravelingjava.html

  • Default Installation Path Permission Requirement (Warning)

    I am trying to install SQL Server 2005 Standard Edition in parallel with SQL Server 2000. The server is a Dell 2650 with 1 GB RAM running Windows 2000 Server.
    The initial part of the setup runs the System Configuration Checker (SCC), which is generating this warning:
    Default Installation Path Permission Requirement (Warning)
    The server is a member of a domain, but I am logged in as the local administrator. The drive is not compressed. There are no file system problems. I am at a loss as to why this warning is occuring, and do not want to proceed until I figure this out.
    (I got this warning on another server as well. That was a test server, so I proceeded. The engine seems to run ok, but SSIS will not load, says a component is missing.  Not sure if the two issues are related or not).
    Any ideas?
    Thanks,
    Mike

    Hi Mike,
    Warnings doesn't stop your installation!! Can you proceed with the installation or else you can point some other installation directory other than C: drive.. This will verify drive formatting and read/write permissions!!
    You can refer the below link for default installation permission
    Check Parameters for the System Configuration Checker

  • Quicktime has somehow become my default installer

    Quicktime has somehow become my default installer how can I change this and make my installer my installer?
    thanks!!!

    Clcik on a file that wants to use QT, CMD+I, click on the drop-down menu in the Open with section, select the Installer.app, click on the Change all button, and close the window. Double-click on the file and it should open with the Installer.app. If not, reset the LaunchServices database as described in http://www.thexlab.com/faqs/resetlaunchservices.html

  • Can't change default installation directory for silent installation of Flash Builder 4.5

    Hello,
    I'm trying to create a custom installation script for Flash Builder 4.5 in silent mode.
    I have created a flash builder msi installer using "Adobe Application Manager Enterprise Edition".
    I would like to change the default installation directory during silent installation.
    Could you please help ?
    Thank you in advance.
    Best regards,
    Ryad

    The install.xml in the "Adobe Flash Builder 4.5 Installer/deploy" folder will have the INSTALLDIR property. You can change this property to your custom location.
    <?xml version="1.0" encoding="UTF-8"?>
    <Deployment>
      <Properties>
        <!--Note that the INSTALLDIR value is machine specific.  The value below is a suggested default value but may need to be overriden.-->
       <Property name="INSTALLDIR">C:\Program Files\Adobe</Property>
      </Properties>
      <Payloads>
    </Payloads>
    </Deployment>
    Thanks
    Unni G S

  • Installation question - Changing the default installation directory

    Is there a way during a silent install to change the default installation path from c:\hyperion? For instance I would like it to install to c:\program files (x86)\Hyperion by default with no user interaction required.

    Not sure what you are trying to install but personally I would steer away from using directories with spaces in
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • Difference between JDK ,SDK ,JRE

    Hi all,
    Im confused about the difference between JDK ,SDK ,JRE.What all is needed to install Java.Please elaborate.

    Even on Venus. ;)
    Goddess on the mountain top
    Burning like a silver flame
    The summit of beauty and love
    And Venus was her name
    She's got it
    Yeah, baby, she's got it
    I'm your Venus, I'm your fire
    At your desire
    Well, I'm your Venus, I'm your fire
    At your desire

Maybe you are looking for

  • How to print monthly view in ical

    I have the most current version of ical.  It wont let us print a monthly view.  It only lets us select fro day or list.  I am sure i am doing someething wrong, but I dont know what.  Running MAC OS X 10.5.8.  Ical version 3.0.8. 

  • CF11 install problem on WIndows server 2012 R2

    We have a new install windows server 2012 R2 with a new install CF11 standard installed on C drive. Everything is 64bit. The CF administrator site and login works fine.  cfm files will not serve up in the default directory, but IIS shows htm files fi

  • File links / drag and drop no longer work with MS Office 2008

    not sure what happened, but my installed and up to date version of MS Office suddenly refuses to accept file open events. Cannot double click on files anymore, nor can I drop files into the MS icons in the dock. The only way to open files is now usin

  • Recovery in NOARCHIVELOG mode. A Sybex Study GUide quibble

    Hi. Actually, this is much more than a quibble as its a crucial point vis a vis the exam. To perform a recovery in noarchivelog mode, we have to restore the db from the last backup. I was under the impression that a backup of the database should NOT

  • AVCHD wont Log and Transfer

    Hello all. So I got this footage that's in the AVCHD format. I have FCS 2, with the latest update. But when I try to use the Log and Tranfer function to open the folder with the clips, I get the error "AVCHD Media is unsupported on PowerPC based hard