Following post will help you to upgrade/change the JDK used by an Oracle WebLogic Server to a newer version.
- Upgrade JDK:
- Make sure new JDK version is certified with Weblogic version and other products installed in the same domain.
- Install New JDK.
- Shutdown Weblogic domain
- Modify all occurrences of the original JDK directory path value with the new JDK directory path value for the files listed below.
- MW_HOME/wlserver_10.3/common/bin/commEnv.sh
- MW_HOME/wlserver_10.3/common/nodemanager/nodemanager.properties
- MW_HOME/utils/bsu/bsu.sh
- MW_HOME/utils/quickstart/quickstart.sh
- MW_HOME/utils/uninstall/uninstall.sh
- MW_HOME/wlserver_10.3/.product.properties
- DOMAIN_HOME/user_projects/domains/<mydomain>/bin/setDomainEnv.sh
- MW_HOME/install/envVars.properties
- MW_HOME/oracle_common/common/bin/commEnv.sh
- MW_HOME/oracle_common/common/bin/setHomeDirs.sh
- MW_HOME/oui/bin/compareInventory.sh
- MW_HOME/oui/bin/install.sh
- MW_HOME/oui/bin/viewInventory.sh
- MW_HOME/wlserver/.product.properties
- DOMAIN_HOME/bin/setDomainEnv.sh
- DOMAIN_HOME/nodemanager/nodemanager.properties
- Clear cache and tmp folders resides in each server folder.
- javax.annotation_1.0.0.0_1-0.jar
- javax.xml.bind_2.1.1.jar
- javax.xml.ws_2.1.1.jar
- Startup Weblogic domain
Note 1: Take backup of below mentioned files before change.
Note 2: Following command will help you find list of files referring to JAVA_HOME
find . -type f -name "*.sh" -exec grep -il JAVA_HOME {} \;
11g:
----
12c:
----
Note: Incase Weblogic version is 10.3.6 and the targetJDK version is JAVA 7 (version 1.7.0_x),following jar files needs to be copied manually from $MW_HOME/modules to the directory $JAVA_HOME/jre/lib/endorsed
Simple way: You can install new JDK and rename new JDK folder name to old JDK name to skip JAVA_HOME path update in all the files mentioned in step 4.
- Change JRockit to JDK and Vice-versa:
-
Refer below steps along with above mentioned JDK upgrade steps.
- Refer below 2 steps and update following two files as needed:
- setDomainEnv.sh
- commEnv.sh
- If you are changing from JRockit to JDK: JAVA_HOME="/usr/bin/jdk1.6.0_31"
- If you are changing from JDK to JRockit: JAVA_HOME="/usr/bin/jrockit_28.1"
JAVA_VENDOR="Sun"
export JAVA_HOME
export JAVA_VENDOR
JAVA_VENDOR="Oracle"
export JAVA_HOME
export JAVA_VENDOR
I learned installing Java successfully and created my first mobile app a few days ago, and it was truly a fun experience. I did it under the guidance of Java experts.
ReplyDelete