Installing OpenJDK for CDP Runtime

This section is optional. The CDP Runtime requires a JDK to be installed on all cluster hosts prior to Cloudera Manager and Runtime installation. Cloudera Manager can automatically install an OpenJDK that has been pre-packaged by Cloudera. This OpenJDK provided by Cloudera may not be the latest version.

If you do not want to use the OpenJDK provided by Cloudera, you must install a JDK of your choice on all hosts in the cluster. These instructions describes how to install the OpenJDK package provided by your Operating System Vendor.

Note that the path for the default truststore for OpenJDK 8* is jre/lib/security/cacerts.
  • The package names used when installing the OpenJDK 8* and OpenJDK 11* are different and are noted in the steps below.
  • The path for the default truststore has changed from (OpenJDK 8*) jre/lib/security/cacerts to (OpenJDK 11*) lib/security/cacerts
  • See the following blog post for general information about migrating to Java 11: All You Need to Know For Migrating To Java 11.

You must install a supported version of OpenJDK. If your deployment uses a version of OpenJDK lower than 1.8.0_181, see TLS Protocol Error with OpenJDK.

  1. Log in to each host and run the command for the version of the JDK you want to install:
    RHEL
    OpenJDK 8 *
    sudo yum install java-1.8.0-openjdk-devel
    OpenJDK 11*
    sudo yum install java-11-openjdk-devel
    Ubuntu
    OpenJDK 8*
    sudo apt-get install openjdk-8-jdk
    OpenJDK 11*
    sudo apt install openjdk-11-jdk
    SLES
    OpenJDK 8*
    sudo zypper install java-1_8_0-openjdk-devel
    OpenJDK 11*
    sudo zypper install java-11-openjdk-devel

  2. Tune the JDK (OpenJDK 11*).

    OpenJDK 11* uses new defaults for garbage collection and other Java options specified when launching Java processes. Due to these changes you may need to tune the garbage collection by adjusting the Java options used to run cluster services, which are configured separately for each service using the service's configuration parameters. To locate the correct parameter, log in to the Cloudera Manager Admin Console, go to the cluster and service you want to configure and search for "Java Configuration Options".

    When using OpenJDK 11*, Cloudera Manager and most Cloudera Runtime services use G1GC as the default method of garbage collection. Java 8 used "ConcurrentMarkSweep" (CMS) for garbage collection. When using G1GC, the pauses for garbage collection are shorter, so components will usually be more responsive, but they are more sensitive to JVMs with overcommitted memory usage. See Tuning JVM Garbage Collection.

* Azul OpenJDK, OpenJDK 8, and OpenJDK 11 are TCK certified for CDP.