Finally, I upgraded the Java version of my CentOS server. Take a note. # Be sure to have installed yuminstall-yjpackage-utils # On the Sun degrees to download the JDKRPM package on Linux # the current version of the jdk-6u6-linux-i586-rpm.bin # If the official website to download, it may need to be uploaded back to the Server through FTP and then installed # change to executable permission chmod + xjdk-6u6-linux-i586-rpm.
Finally, I upgraded the Java version of my CentOS server. Take a note.
# Be sure to have been installed
Yum install-y jpackage-utils
# Download the jdk rpm package on Linux from Sun
# Current version is jdk-6u6-linux-i586-rpm.bin
# If the download is from the official website, it may need to be uploaded back to the Server through FTP and then installed
# Change to executable permission
Chmod + x jdk-6u6-linux-i586-rpm.bin
# Execute
/Jdk-6u1-linux-i586-rpm.bin
# Download the JDK 6 file starting with java-1.6-sun at the following URL
Http://mirrors.dotsrc.org/jpackage/1.7/generic/non-free/RPMS/
# The RPM generated before installation
# Install the downloaded file again
Rpm-Uvh jdk-6u6-linux-i586.rpm & rpm-Uvh java-1.6.0-sun-compat-1.6.0.06-1jpp.i586.rpm
# If you need to change the native path, you can use
Rm-f/usr/bin/java
# Select the JVM default version of Java IN THE SYSTEM
# Two should be displayed, and the latest version should be used. So I chose 2.
/Usr/sbin/alternatives -- config java
# Check whether the beta version has been updated.
Java-version
# If the version is not the latest or the old version, you can use
Rm-f/usr/bin/java & ln-s/usr/java/jre1.6.0 _ 10/bin/java/usr/bin/java