For example if you want to uninstall the java-1.8.0-openjdk-devel package simply run: If for any reason you want to uninstall the Java package, you can unistall it as any other package installed with yum. Just enter the number when prompted and hit Enter. The output should look similar to the following: If we have multiple Java versions installed on the server we can change the default version using the alternatives system: Java HotSpot(TM) 64-Bit Server VM (build 9.0.4+11, mixed mode)
We can check the version of our default Java, with: Sudo yum localinstall jdk-8u162-linux-圆4.rpm Sudo yum localinstall jre-8u162-linux-圆4.rpm Sudo yum localinstall jdk-9.0.4_linux-圆4_bin.rpm Sudo yum localinstall jre-9.0.4_linux-圆4_bin.rpm Sudo yum install java-1.7.0-openjdk-devel Sudo yum install java-1.8.0-openjdk-devel The installation is simple and straightforward. OpenJDK, the open source implementation of the Java Platform is the default Java development and runtime in CentOS 7.
There are also two different implementations of Java, OpenJDK and Oracle Java with almost no differences between them except that Oracle Java has a few additional commercial features.