首先查看JDK的版本,java -version
卸载步骤如下:
[root@localhost ~]# rpm -qa|grep jdk java-1.6.0-openjdk-1.6.0.0-1.50.1.11.5.el6_3.x86_64 java-1.7.0-openjdk-1.7.0.9-2.3.4.1.el6_3.x86_64 [root@localhost ~]# rpm -qa|grep gcj java-1.4.2-gcj-compat-1.4.2.0-40jpp.115 libgcj-4.1.2-48.el5 [root@localhost ~]# yum -y remove java java-1.6.0-openjdk-1.6.0.0-1.50.1.11.5.el6_3.x86_64 [root@localhost ~]# yum -y remove java java-1.7.0-openjdk-1.7.0.9-2.3.4.1.el6_3.x86_64 [root@localhost ~]# yum -y remove java java-1.4.2-gcj-compat-1.4.2.0-40jpp.115 [root@localhost ~]# yum -y remove libgcj-4.1.2-48.el5