Migrate from Oracle Java JDK to Open JDK for Windows
Modified on: Wed, 24 Jan 2024 8:43 AMIntroduction
As of January 2019 Oracle Java SE/JDK is now a paid product and can no longer be installed for free in a commercial production environment. A free version with a GNU License is being maintained under the OpenJDK initiative and is equivalent to the latest versions of the Oracle Java JDK. This article will describe the steps to migrate or upgrade from Oracle Java JDK to Open JDK on the Windows operating system.
Applicability
This article applies to anyone that has installed Oracle Java on a workstation or server and wishes to migrate to a free version of the software.
Procedure
- Open a browser and download the latest "Ready for Use" version of the JDK from https://jdk.java.net/
- Extract the OpenJDK files to C:\Program Files\OpenJDK
- Update the Java Machine Path to "C:\Program Files\OpenJDK\bin\server\jvm.dll" for any applications that need it, for example Tomcat.
- Add the following to the PATH system environment variable: C:\Program Files\OpenJDK\bin
- Restart any applications that are directly targeting the Java Machine DLL (JVM.DLL) modified in step 3.
- Remove all Oracle Java installations from the "Add or Remove Programs" control panel.
- Remove, if exists, "C:\ProgramData\Oracle"
- Remove, if exists, from the PATH system environment variable any path beginning with "C:\ProgramData\Oracle" for example: "C:\ProgramData\Oracle\Java\Javapath"
- Open command prompt to test if java is still working with either or both "java --version" and "javac --version". You should see the version of the OpenJDK you installed displayed.
Additional Considerations (Notes)
There is no update manager or notifications for updates. Any updates will need to be handled manually by the user. The intended update cycle is every 6 months. If you need assistance with this please contact IST.
Keywords: Oracle Java OpenJDK JDK Migrate Upgrade Windows