Jump to: navigation, search
Line 1: Line 1:
 
=Migrating from Oracle Java 8 to OpenJDK 1.8.0=
 
=Migrating from Oracle Java 8 to OpenJDK 1.8.0=
To upgrade Java, Open Java Runtime Environment (JRE) or Java Development Kit (JDK) RPM packages are recommended:
+
To upgrade Java, the following Open Java Runtime Environment (JRE) or Java Development Kit (JDK) RPM packages are recommended:
 
* java-1.8.0-openjdk-headless
 
* java-1.8.0-openjdk-headless
 
* java-1.8.0-openjdk-devel
 
* java-1.8.0-openjdk-devel
  
The RPM packages execute all necessary actions to install, configure Java, and update the operating system (OS) configuration. '''Web Services and Applications''' uses the default Java that is configured on the node. Therefore, if Oracle Java was installed previously using a Java RPM package, the newly installed/updated OpenJDK should be selected as default one.  
+
The RPM packages execute all necessary actions to install and configure Java, and update the operating system (OS) configuration. '''Web Services and Applications''' uses the default Java version that is configured on the node. Therefore, if Oracle Java was installed previously using a Java RPM package, the newly installed/updated OpenJDK should be selected as default one.  
  
Invoke <tt>update-alternatives util</tt> and select the required java installation:
+
Invoke <tt>update-alternatives util</tt> and select the required Java installation:
  
 
'''update-alternatives --config java'''
 
'''update-alternatives --config java'''
Line 39: Line 39:
 
|}
 
|}
  
After typing the command, press '''Enter''' to retain the current selection[+], or type selection number.
+
After typing the required command, press '''Enter''' to retain the current selection[+], or type the selection number.
  
In some cases, it might not possible to update the default Java on the node. Complications with other applications or circumstances might prevent a successful update. In this case, you can configure Web Services and Applications to use a specific Java version. Use the JAVA variable in the '''/etc/default/gws''' file. For example:
+
In some cases, it might not be possible to update the default Java version on the node. Complications with other applications or circumstances might prevent a successful update. In this case, you can configure Web Services and Applications to use a specific Java version. Use the JAVA variable in the '''/etc/default/gws''' file. For example:
  
 
<tt>
 
<tt>

Revision as of 10:56, December 12, 2019

Migrating from Oracle Java 8 to OpenJDK 1.8.0

To upgrade Java, the following Open Java Runtime Environment (JRE) or Java Development Kit (JDK) RPM packages are recommended:

  • java-1.8.0-openjdk-headless
  • java-1.8.0-openjdk-devel

The RPM packages execute all necessary actions to install and configure Java, and update the operating system (OS) configuration. Web Services and Applications uses the default Java version that is configured on the node. Therefore, if Oracle Java was installed previously using a Java RPM package, the newly installed/updated OpenJDK should be selected as default one.

Invoke update-alternatives util and select the required Java installation:

update-alternatives --config java

There are four programs that provide 'Java':

Selection

Command

1

/usr/lib/jvm/java/bin/java

2

/usr/lib/jvm/jre-1.6.0-openjdk.x86_64/bin/java

3

/usr/java/jdk1.8.0_92/jre/bin/java

*+4

/usr/lib/jvm/jre-1.8.0-openjdk.x86_64/bin/java

After typing the required command, press Enter to retain the current selection[+], or type the selection number.

In some cases, it might not be possible to update the default Java version on the node. Complications with other applications or circumstances might prevent a successful update. In this case, you can configure Web Services and Applications to use a specific Java version. Use the JAVA variable in the /etc/default/gws file. For example:

# JAVA
# defines the Java that have to be used if several versions are installed on the host.
JAVA=/usr/lib/jvm/jre-1.8.0-openjdk.x86_64/bin/java

Comments or questions about this documentation? Contact us for support!