Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 13 Next »

Windows

Install new Java version

Follow instructions to install Java: https://phixflow.atlassian.net/wiki/pages/createpage.action?spaceKey=HELP83&title=Install%20Java%20OLD

Update JAVA_HOME

If you have set the environment variable JAVA_HOME, check whether this needs updating in the system environment variables. Commonly this will be automatically updated by the installation process.

Update service wrapper

Find the file jvm.dll in the Java installation.

  • Java 8: this will be in JAVA_HOME\jre\bin\server\jvm.dll

  • Java 11: this will be at JAVA_HOME\bin\server\jvm.dll

Open Tomcat Properties window. If you need further details on how to open this, see: Tomcat start/ stop, open properties

Go to the Java tab. Update the Java Virtual Machine setting to the new location of jvm.dll.

If you have moved between major versions of Java (e.g. you are moving from Java 8 to Java 11), update the Java arguments as instructed here: Install Tomcat on Windows

Remove old version

Installation of a new patch of Java should replace the previous version.

If you are migrating to a new major version of Java (e.g. you are moving from Java 8 to Java 11), you will need to remove the previous version from the list of installed programs.

Linux

Install new Java version

Follow instructions to install Java: Install Java

Update JAVA_HOME

If you have followed the standard installation instructions, you have already done this. If you have decide to take a different approach, remember to update JAVA_HOME in whichever way you have decided to set this.

Update service script

The following instructions assume that you have followed the recommended installation instructions for installing Tomcat for PhixFlow: Install Tomcat on Linux. If you have taken a different approach, ensure that you update JAVA_HOME in your startup process for Tomcat.

Open the tomcat service script at /etc/systemd/system/tomcat.service

Update JAVA_HOME in the script to the value of $JAVA_HOME in your environment. You must make this the full path for the Java installation, you cannot refer to the environment variable in the script. The resulting file will look similar to this:

[Unit]
Description=Apache Tomcat Web Application Container
After=network.target

[Service]
Type=forking

Environment=JAVA_HOME=/opt/jdk/jdk-11.0.13+8
Environment=CATALINA_PID=/opt/tomcat/temp/tomcat.pid
Environment=CATALINA_HOME=/opt/tomcat
Environment=CATALINA_BASE=/opt/tomcat

If you have moved between major versions of Java (e.g. you are moving from Java 8 to Java 11), update the CATALINA_OPTS as instructed here: Install Tomcat on Linux

Remove old version

The following instructions assume that you have followed the recommended instructions for installing Java for PhixFlow: Install Java. If you have taken a different approach, ensure that any old packages have been removed if you no longer need them (e.g. for a different program that runs on the same server that requires the previous version of Java).

If you have patched Java with a package manager, it will replace the previous version. However, if you are moving between major versions (e.g. from Java 8 to Java 11), you will need to remove the previous version using the package manager.

Delete the previous installation:

cd /opt/jdk
sudo rm -r [PREVIOUS VERSION]

For example:

sudo rm -r /opt/jdk/jdk-11.0.13+8

  • No labels