Installing JVM

The Java Virtual Machine (JVM) allows our enterprise application, application server and IDE, to run. Sun Microsystems provides JVMs for Linux, Solaris and Windows operating systems.

There are two principal products in the Java SE family: Java SE Development Kit (JDK) and Java SE Runtime Environment (JRE).

The JRE provides the Java APIs, Java Virtual Machine (HotSpot VM), and other components necessary to run applets and applications written in the Java programming language. It can be redistributed with such applications.

The JDK contains everything that is in the JRE, plus tools such as the compilers and debuggers necessary for developing applets and applications.

It is important to note that the JDK is to be downloaded, the JRE should NOT be downloaded. The JRE does NOT contain the compiler, which Eclipse and JBoss require.

  1. Download JDK 5.0 from http://java.sun.com/javase/downloads/index.jsp to some temporary folder (C:\temp).

  2. Run the JDK 5.0 installation program by running the following file:

    C:\temp\jdk-1_5_0_09-windows-i586-p.exe
    								

    Read and accept the license agreement.

    Accept the default destination directory.

  3. Set the JAVA_HOME Environment Variable

    The environment variable called JAVA_HOME is used by many Java applications, including JBoss. It is therefore necessary to make sure that this environment variable is setup correctly after Java has been installed.

    On Windows Systems, in the control panel, the System icon is opened. The Advanced Tab is selected, and the Environment Variables button is pressed.

    Click the New button in the User variables section. Add the new variable called JAVA_HOME, its value is the root installation of the Java SDK (C:\Program Files\Java\jdk1.5.0_09):

    New JAVA_HOME environment variable

  4. Update the PATH Environment Variable

    Open the Environment Variables dialog and select the PATH variable in the User variables section.

    Click the Edit button.

    Update variable to point to the binary folder of JDK just installed (C:\Program Files\Java\jdk1.5.0_09\bin):

    Update PATH environment variable

  5. Verify the JAVA_HOME environment variable:

    C:\>set JAVA_HOME
    
    JAVA_HOME=C:\Program Files\Java\jdk1.5.0_09
    								

  6. Verify the PATH environment variable:

    C:\>java -version
    
    java version "1.5.0_09"
    Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_09-b01)
    Java HotSpot(TM) Client VM (build 1.5.0_09-b01, mixed mode, sharing)
    								

Professional hosting     Belorussian informational portal         Free SCWCD 1.4 Study Guide     Free SCDJWS 1.4 Study Guide     SCDJWS 1.4 Quiz     Free IBM Certified Associate Developer Study Guide     IBM Test 000-287. Enterprise Application Development with IBM WebSphere Studio, V5.0 Study Guide     Free Mock Exam Engine