Skip to main content

Home

Java Runtime Environment (JRE)

Unravel requires Java Runtime Environment (JRE) and hence it is shipped with OpenJDK version 17.0.1. If you have a different version of JDK installed, you must configure Unravel to access the corresponding jre directory in that JDK.

Do the following steps to set the path to the jre directory in Unravel:

Note

In a multi-cluster deployment, you must configure the jre directory both on the edge node as well as on the core node.

  1. Stop Unravel.

    <Unravel installation directory>/unravel/manager stop
  2. Open the <Unravel_installation_directory>/unravel/data/conf/unravel.yaml file using an editor and look for the home: attribute. If this does not exists, you can add it under the current hosts: attribute. For example:

    ```
    hosts:
    host_main:
    home:
    ```
  3. Add the path of the custom JDK location to the home: > java: attribute.

    ```
    hosts:
    host_main:
    home:
    java: </path/to/jre>
    ```
    

    For example:

    ```
    hosts:
    host_main:
    home:
    java: /tmp/jdk1.8.0_112/jre
    ```
    
  4. Apply the changes.

    <Unravel installation directory>/unravel/manager config apply
  5. Start Unravel.

    <Unravel installation directory>/unravel/manager start
  6. Validate the JAVA version that Unravel is using now:

    1. Go to Unravel node and login as unravel user. In the case of multi-cluster, go to Unravel edge node.

    2. Run the following command:

      ps -ef | grep unravel | grep java

      For example, the following output is shown:

      unravel 26871 1 1 Jul05 ? 00:30:43 /tmp/jdk1.8.0_112/jre/bin/java -server -Dident=unravel_taw_1 -Dunravel.log.dir=/opt/unravel/logs -Dhadoop.version= -Djdbc.driver.jar=com.mysql.jdbc.Driver -Dhadoop.conf.dir=/etc/hadoop/conf -Djava.awt.headless=true -Djava.net.preferIPv4Stack=true -Dnetworkaddress.cache.ttl=30 -Dsun.net.inetaddr.ttl=30 -Xmx6g -Xms1g -Dvertx.cacheDirBase=/opt/unravel/tmp/ver

      In the above example, the Java /tmp/jdk1.8.0_112/jre/bin/java is chosen by Unravel.

    3. You can further validate the Java version. For example, run the following command:

      /tmp/jdk1.8.0_112/jre/bin/java -version