Using OpenJDK 11 instead of Java SE 15
The bundled Neo4j 4.4 graph database runs on Java 11, but the Forestall installer ships Java(TM) Platform SE 15 as its prerequisite. If you need an OpenJDK LTS release, you can replace Java SE 15 with OpenJDK 11. OpenJDK 11 is supported.
The Neo4j service is registered against the java.exe found when neo4j.bat install-service runs, so the service has to be reinstalled after Java is replaced.
Download OpenJDK 11
Download the OpenJDK 11 JRE that has been tested with Forestall:
OpenJDK11U-jre_x64_windows_hotspot_11.0.24_8.msi
Both methods remove Java SE 15 before OpenJDK 11 is installed, so the two versions never run side by side. Plan a short maintenance window. If you can, try the switch on a non-production server first.
Method 1: Run the upgrade script (recommended)
Run Upgrade-Java-To-OpenJDK11.ps1 from C:\Forestall\FSProtect\setup-files\scripts\utils\ in an elevated PowerShell session:
.\Upgrade-Java-To-OpenJDK11.ps1 -MsiPath "C:\path\to\OpenJDK11U-jre_x64_windows_hotspot_11.0.24_8.msi"The script:
Finds and silently uninstalls Java SE 15.
Installs the OpenJDK 11 MSI silently, with the options that set
JAVA_HOMEandPATH.Fails with an error if
JAVA_HOMEis still not set afterwards.Removes the
dbms.jvm.additional=-XX:G1PeriodicGCIntervalline fromneo4j.conf.Reinstalls and starts the Neo4j Windows service against the new
java.exe.Runs
iisreset.exe.
If it exits with an MSI error, check the log it prints (%TEMP%\OpenJDK11-install.log) before retrying.
Method 2: Manual steps
On the Forestall server, open Settings > Apps > Installed apps (or Add or remove programs) and uninstall Java SE Development Kit 15.
Run the OpenJDK 11 MSI you downloaded as Administrator and complete the wizard with the default options.
Open
C:\Forestall\FSProtect\neo4j\neo4j-community-4.4.8\conf\neo4j.confand delete the last line:In an elevated PowerShell session, reinstall and start the Neo4j service, then restart IIS:
Verify
Confirm the
neo4jservice is Running (Get-Service neo4j).Open the Health Check page and confirm the Neo4j Graph Database checks for API and Core show Running.
Rollback
To go back to Java SE 15:
Uninstall OpenJDK 11 and reinstall Java SE 15. The installer is part of the Forestall installation package. Contact Forestall support if you no longer have it.
Add
dbms.jvm.additional=-XX:G1PeriodicGCInterval=5000back to the end ofneo4j.conf.Reinstall the Neo4j service and restart IIS with the same commands as in Method 2, step 4.
Last updated
Was this helpful?