Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Java version detection not working correctly

Kevin Weis January 7, 2019

I followed the steps from@Jakub Lazinskihttps://community.atlassian.com/t5/Agile-articles/Java-11-OpenJDK-support-update-for-Server-and-Data-Center/ba-p/967836#M402

I set JIRA_HOME="/etc/alternatives/jre/" in bin/setenv.sh

When starting the service i get the following error message:

Wrong JVM version! You are running with openjdk version "11.0.1" 2018-10-16 LTS but JIRA requires at least 1.8 to run

System details:

  • CentOS 7 (up-to-date)
  • atlassian-jira-software-7.13.0-x64
  • PostgreSQL 9.6
  • OpenJDK 11 (java-11-openjdk-11.0.1.13-3.el7_6.x86_64)

"/etc/alternatives/jre" is a symlink to "/usr/lib/jvm/java-11-openjdk-11.0.1.13-3.el7_6.x86_64"

the "java" executable is therefore located at "/usr/lib/jvm/java-11-openjdk-11.0.1.13-3.el7_6.x86_64/bin/java"

2 answers

1 accepted

1 vote
Answer accepted
Earl McCutcheon
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
January 9, 2019

Hello,

Currently, you are going to want to use the AdoptOpenJDK 8 (HotSpot) as openJDK 11 is not fully recognized yet, and as of 7.13.0 it is not fully tested and verified so there could still be conflict points.  It is not yet officially supported as covered in the Jira 7.13 Supported Platforms documentation.

Then keep an eye on https://jira.atlassian.com/browse/JRASERVER-41589, for an update on Java 11 noting the most recent update in the section "Atlassian Update – 22 August 2018":

Hi everyone,

Thank you for your insights and thoughts on this issue.
We've recently posted an update regarding this topic on community for all Atlassian Server & Data Center products.

Please read it here → https://community.atlassian.com/t5/Jira-discussions/Java-11-and-OpenJDK-support-for-Atlassian-Server-amp-Data-Center/m-p/872998#M4575

We'll provide further updates on the progress of work for supporting OpenJDK 11 for Jira within the next few months.

Kind regards,
Jira Product Management

Regards,
Earl

Kevin Weis January 9, 2019 edited

Many thanks!

Switching to "java-1.8.0-openjdk.x86_64" worked for me.

I'll keep waiting for the support of OpenJDK 11 :)

0 votes
Jeff Blaine
Contributor
September 6, 2019

This fails for us on 7.13.3 when using OpenJDK 1.8.0.

[m26560@etc-jira-dev ~]$ /usr/lib/jvm/java-1.8.0-openjdk/bin/java -version
openjdk version "1.8.0_222"
OpenJDK Runtime Environment (build 1.8.0_222-b10)
OpenJDK 64-Bit Server VM (build 25.222-b10, mixed mode)
[m26560@etc-jira-dev ~]$

The failure comes when $JIRA_HOME/bin/check-java.sh runs because it is hardcoded to look for the string "java" in the output of that command. The line of code in check-java.sh is:

"$_RUNJAVA" -version 2>&1 | grep "java version" | ...

 As you can see from the terminal paste above, the string for OpenJDK is "openjdk"

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, atlassian government cloud, fedramp, webinar, register for webinar, atlassian cloud webinar, fedramp moderate offering, work faster with cloud

Unlocking the future with Atlassian Government Cloud ☁️

Atlassian Government Cloud has achieved FedRAMP Authorization at the Moderate level! Join our webinar to learn how you can accelerate mission success and move work forward faster in cloud, all while ensuring your critical data is secure.

Register Now
AUG Leaders

Atlassian Community Events