Linux installation JDK

Source: Internet
Author: User

1, for http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html
Direct download, then jump page select platform in the Linux download, I did not register, Direct point continue go to the next page, select the type of package you want to download, I choose
jdk-7u5-linux-i586.rpm the speed of the fast words will be finished.

2. Mkdir/usr/java----New Java folder

3. Copy the downloaded JDK to the new Java directory

4. Modify executable permissions:

#chmod u+x jdk-7u5-linux-i586.rpm

5. Installing the JDK

RPM-IVH jdk-7u5-linux-i586.rpm

6. Increase environment variables

Vi/etc/profile

Add the following on the last side of the file:

Export java_home=/usr/java/jdk1.7.0_79
Export Java_bin=/usr/java/jdk1.7.0_79/bin
Export path= $PATH: $JAVA _home/bin
Export classpath=.: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar
Export Java_home java_bin PATH CLASSPATH

Save exit: Wq

7. Enter the/usr/bin/directory

Cd/usr/binln-s-f/usr/java/jdk1.7.0_79/jre/bin/javaln-s-f/usr/java/jdk1.7.0_79/bin/javac

8. View environment variable Java-version

Success!

Reference from: http://blog.sina.com.cn/s/blog_6d39ac7e010191zy.html

Http://www.jizhuomi.com/android/environment/124.html

Http://blog.chinaunix.net/uid-12115233-id-3304951.html

Linux installation JDK

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.