Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
76:upgrade_java [2022/01/13 11:51] – created vtbr76:upgrade_java [2024/02/15 00:00] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +====== Upgrade Java for Stages ======
 +
 +\\
 If you need to upgrade your Java version please proceed as follows: If you need to upgrade your Java version please proceed as follows:
  
-  * Backup the //cacerts //file from the location of the existing JDK //[...]/ jdk_<old>/jre/lib/security/ or create a new //cacerts//  file including the necessary certificates (e.g. company root certificate). +  * Backup the cacerts file from the location of the existing JDK ''/jdk_<old>/jre/lib/security/''  or create a new cacerts file including the necessary certificates (e.g. company root certificate). 
-  * Install JDK of new Java version on server. Please refer to the system requirements for supported JDK editions. +  * Install JDK of new Java version on server. Please refer to the [[:76:system_requirements|system requirements 7.6]] for supported JDK editions. 
-  * Copy the //cacerts //file to the location of the new JDK// [...]/ jdk_<new>/jre/lib/security ./+  * Copy the cacerts file to the location of the new JDK ''/jdk_<new>/jre/lib/security/'' 
-  * Change //JAVA_HOME//  in //<stages>/config.bat//  according to the location of the new JDK and run //<stages>\bin\reinstallservice.bat//  (as admin).+ 
 +=== Windows: === 
 + 
 +  * Change JAVA_HOME in <stages>\config.bat according to the location of the new JDK and run <stages>\bin\reinstallservice.bat (as admin). 
 + 
 +=== Linux: === 
 + 
 +  * Execute the following as root or with sudo 
 +  * Create new file that is getting loaded when system is starting/restarting 
 +<code> 
 + 
 +touch /etc/profile.d/java_home.sh 
 + 
 +</code> 
 + 
 +  * Fill the file with variable definition to have an always up to date definition of the JDK in JAVA_HOME and PATH env. variables 
 + 
 +<code> 
 +cat <<EOF> /etc/profile.d/java_home.sh 
 +export JAVA_HOME=\$(readlink -f /usr/bin/java | sed "s:/bin/java::"
 +export PATH=\$PATH:\$JAVA_HOME/bin 
 +EOF 
 + 
 +</code> 
 + 
 +  * Reload the environment variables with the following command or restart the system 
 +<code> 
 + 
 +source /etc/profile 
 + 
 +</code>