Upgrading the publishing server from 4.4 to 4.5
The following procedure aims at upgrading the pubserver from version 4.4 to 4.5. Make sure you are running version 4.4 before continuing.
To upgrade:
- Stop the pubserver.
- Rename
PUBSERVER\java\jdk
folder containing JDK 11 toPUBSERVER\java\jdk_11_bkp
. - Copy
PUBSERVER\java\jdk17
folder containing JDK 17 toPUBSERVER\java\jdk
. We recommend setting Java 17 as the default Java in your environment from now on. This might mean updating yourPath
and/orJAVA_HOME
environment variable to point toPUBSERVER\java\jdk\bin
. All in all, you want to run the updater using Java 17 from now on. - Edit
PUBSERVER\glassfish\payara5\glassfish\domains\pubserver\config\domain.xml
and just before the line
<jvm-options>-Xmx8192m</jvm-options>
insert the following options:
<jvm-options>[17|]--add-exports=java.base/sun.net.www=ALL-UNNAMED</jvm-options>
<jvm-options>[17|]--add-exports=java.base/sun.security.util=ALL-UNNAMED</jvm-options>
<jvm-options>[17|]--add-opens=java.base/java.lang.invoke=ALL-UNNAMED</jvm-options>
<jvm-options>[17|]--add-opens=java.desktop/java.beans=ALL-UNNAMED</jvm-options>
<jvm-options>[17|]--add-exports=jdk.naming.dns/com.sun.jndi.dns=ALL-UNNAMED</jvm-options>
<jvm-options>[17|]--add-opens=java.base/java.lang.ref=ALL-UNNAMED</jvm-options>
- Remove the contents of
PUBSERVER\glassfish\payara5\glassfish\domains\pubserver\generated
andPUBSERVER\glassfish\payara5\glassfish\domains\pubserver\osgi-cache
- Start the pubserver.
- Run the updater updating to 4.5. Both the installer and the pubserver should now run using JDK 17.
- If all works fine, remove
PUBSERVER\java\jdk_11_bkp
.