ALM On-Prem Installation of 2020 R1 fails to install on Open JDK 8 with the following error
Problem: ALM On-Prem Installation of 2020 R1 fails to install if Open JDK 8 is installed with the following error
Windows: After InstallAnywhere extracts the content it fails with a java message: Could not find a valid Java virtual machine to load. You may need to reinstall a supported Java virtual machine.
Linux: [fno@fnorhel]$ sudo ./FlexNetOperations_2020-R1_installer.bin
Preparing to install
Extracting the installation resources from the installer archive...
Configuring the installer for this system's environment...
No Java virtual machine could be found from your PATH environment variable. You must install a VM prior to running this program.
Solution: The java version should be automatically picked by the installer. For Oracle JDK if java is installed using a JDK installer then FNO installer will pick that JDK. If oracle JDK is a zip distributable then JAVA_HOME needs to be set.
In the case of open-JDK JAVA_HOME must be set for the installer to pick
1. Downloaded the OpenJDK zip file.
2. extracted it to C:\Program Files\Java\
3. set the system environment variable JAVA_HOME as "C:\Program Files\Java\jdk1.8.0_211"
4. set the system path variable as "C:\Program Files\Java\jdk1.8.0_211\bin"
5. Go to directory "C:\Program Files\Java\jdk1.8.0_211\bin" and executed "java -version" to see if Java is fine.
6. Go to the home directory and again executed "java -version" to see JAVA_HOME variable picked up by the system.
7. Go ahead with the installation of FNO and it worked fine.
For Linux: Make sure you set the JDK path in /etc/profile too
for eg : add the below line in /etc/profile -> export PATH=$PATH:/usr/lib/jvm/java-1.8.0-openjdk-184.108.40.206.b08-0.el7_7.x86_64/bin
If we Have multiple JDK( jdk 8 and 11) and verify which one installer picks
The installer should only pick JDK 8 if using oracle JDK.
Note: If using open JDK 8 specify java while installing using LAX_VM. For open-JDK installer won't pick by default since open-JDK doesn't come as an installer so there won't be any registry entry for that. If LAX VM is not passed then the installer would pick from JAVA_HOME
FlexNetOperations_2020-R1_installer.exe LAX_VM "C:\Program Files\Java\java-1.8.0-openjdk-220.127.116.11-3.b09.redhat.windows.x86_64\bin\java.exe"
./FlexNetOperations_2020-R1_installer.bin LAX_VM "/usr/lib/jvm/java-1.8.0-openjdk-18.104.22.168.b08-0.el7_7.x86_64/jre/bin/java".
Note: Officially tested only with RedHat Open JDK.