JSPWiki/Glassfish Install (Part 7 of 18: Install Java SE JDK)

Locate the JDK you downloaded in Step 4. This file will be named “jdk-6-windows-i586.exe.”

Double click on the file to begin the install procedure

  1. Accept the license agreement.
  2. Change the install location for the JDK
    • From: C:\Program Files\Java\jdk1.6.0
    • To: C:\java\jdk1.6.0

and click “Next” to continue.

Eventually the install process will attempt to install a public Java Runtime Environment (JRE). Change the install location for the JRE

  • From: C:\Program Files\Java\jre1.6.0
  • To: C:\java\jre1.6.0

and click to “Next”.

Let the install procedure continue and accept any screens presented.

After the install completes you can verify that you installed to the correct (for this example anyway) location. Look on your “C:” drive for the “java” folder. Inside it should be two folders: jdk1.6.0 and jre1.6.0

After checking the location verify that you can run java commands…

  1. Click on the “Start” Button
  2. Click on “Run…”
  3. In the “Open:” box enter “cmd” and click “OK”
  4. A command window will open
  5. Type “java -version” in the command window
  6. You will get a response indicating that you are running “Java version “1.6.0””

We now have our JDK installed and access to a working JRE which we will need in future steps.

But we’re not finished yet. We will want to setup a few environment variables which may serve to keep us out of trouble later.

Right click on your “My Computer” icon and choose properties.

  1. Click the “Advanced Tab”
  2. Click the “Environment Variables” button
  3. Under the “System Variables” section of the window click “New”
  4. Enter the “Variable Name” — JAVA_HOME
  5. Enter the “Variable Value” — C:\java\jdk1.6.0
  6. Click OK.

Again, under the “System Variables” section of the window click “New”

  1. Enter the “Variable Name” — JDK_HOME
  2. Enter the “Variable Value” — C:\java\jdk1.6.0
  3. Click OK.
  4. Under the “System Variables” find the system variable with then name “Path”
  5. Click “Edit”
  6. Add “;%JAVA_HOME%\bin” to the very end of the “Variable Value” field
  7. Click OK.
  8. Click OK to close the “Environment Variables” window
  9. Click OK to close the “System Properties” window.

Consider the JDK installed!

Our “java” folder now looks like this:

C: java
\–jdk1.6.0
\–jre1.6.0