

However: On RHEL, Java installations are installed with the -slave option to -install so that the JRE is switched in lockstep with the java program. The vanilla Debian tool also has update-alternatives -query jre_1.8.0_openjdk for a machine-readable form that can be used in pipelines, which your system does not have, however. Which should tell you the "generic name" to use with -install. With that tool, and your port, there is update-alternatives -display jre_1.8.0_openjdk Your alternatives tool is a port of the original Debian update-alternatives tool. This is the correct approach to hand-inserting an alternative in the alternatives system. I'm not even sure that this is the correct approach towards updating java version. I am not sure what to put as the in alternatives -install in order to update /etc/alternatives/jre_1.8.0_openjdk. Which modified /etc/alternatives/java but due to the fact that $JAVA_HOME=/etc/alternatives/jre_1.8.0_openjdk I need to modify/update /etc/alternatives/jre_1.8.0_openjdk. Using the man pages of alternatives I did:Īlternatives -install /usr/bin/java java /usr/lib/jvm/jre-1.8.0-openjdk-1.8.0.251/bin/java tar.gz from artifactory, extract it in /usr/lib/jvm/jre-1.8.0-openjdk-1.8.0.251 and now I need to update all the simlink in order to use the latest java version. I need to update to version 251 so I took the corresponding. $ ls -ltr /etc/alternatives/jre_1.8.0_openjdk I have the following setup (on multiple machines with RHEL7):
