Installing Java for Confluence

This page contains instructions for installing a Java Development Kit (JDK). This is a manual step that is only required for Confluence installations where you are installing from a zip or archive file.

(info) If you are using the automated installer, the required Java files are bundled and will be automatically put in place, hence you will not need to follow the instructions on this page.

Please refer to our Supported Platforms topic for details of the Java versions that are supported for Confluence.

Installing the JDK

A JDK (Java Development Kit) needs to be installed on the same server machine that will have Confluence installed.

  For Windows: (click to expand)

Installing the JDK on Windows

  1. If you are not sure whether you have a JDK installed, please confirm by doing the following:
    • Check Control Panel > Programs and Features in Windows 7 (just Programs on older version of Windows).
    • Java should appear as a line item in the list. If not, you do not have Java installed.
  2. To install the JDK, follow these instructions:
    • Go to the Java download page.
    • Download the version entitled 'Java SE Update XX (JDK)', where 'XX' stands for some number (you should choose the version listed on our Supported Platforms page).
    • When the download has finished, run the Java installer. At one point, you will be asked to choose a directory to install to. Copy or write this directory down for use later.
  3. Check that the JAVA_HOME  environment variable has been set correctly.
    • Open the Start menu, choose Run, type cmd in the Run dialog box and click OK.
    • In the command prompt window, type echo %JAVA_HOME% and then press Enter.
    • View the result:
      • If a directory path is displayed that looks similar to one of the following examples, with the letters 'JDK' immediately preceding a series of version numbers, and this path matches the location where you installed the JDK in step 2, then your JDK has been successfully installed and your JAVA_HOME environment variable has been set correctly.
        Examples of typicalJAVA_HOMEenvironment variable values:
        • C:\Program Files\Java\JDK7
        • C:\Progra~1\Java\JDK7
        • C:\Java\JDK7
        • C:\JDK7
      • If nothing is displayed or you do not see 'JDK' immediately followed by a series of version numbers (like one of the examples above), then you need to set the JAVA_HOME environment variable. Please follow these instructions to set your JAVA_HOME environment variable to the directory you where you have just installed the JDK. By default, this directory is under C:\Program Files\Java.

Note: Any Java or JDK version numbers on this page are examples only. Please refer to the Supported Platforms page for the supported versions of Java.

  For Linux: (click to expand)

Installing the JDK on Linux

  1. If you are not sure whether you have JDK installed correctly, please confirm by doing the following:
    1. Open a shell console.
    2. Type echo $JAVA_HOME in the shell console and then press Enter
    3. View the result:
      • If a line is displayed such as /opt/JDK7 or /usr/lib/jvm/java-7, then your JDK is installed and properly configured.
      • If nothing is displayed, then you either need to install the JDK or set the $JAVA_HOME environment variable. You can set this environment variable in your user account's 'profile' file. Alternatively, you can set this after installing Confluence, by defining this path in your Confluence installation's setenv.sh file, usually located in the Confluence bin directory.
      • If you have installed an unsupported JDK and you want to use SSL then you need to install the Sun JSSE package.
  2. If you need to install the JDK, follow these instructions:
    • Go to the Java download page.
    • Download the version entitled 'Java SE Update XX (JDK)', where 'XX' stands for some number (you should choose the version listed on our Supported Platforms page).
    • When the download has finished, run the Java installer. Detailed installation instructions are provided on Oracle's website.

Note: Any Java or JDK version numbers on this page are examples only. Please refer to the Supported Platforms page for the supported versions of Java.

Was this helpful?

Thanks for your feedback!

Why was this unhelpful?

Have a question about this article?

See questions about this article

Powered by Confluence and Scroll Viewport