Ubuntu12.4 install jdk1.8 and ubuntu12.4jdk1.8

Source: Internet
Author: User

Ubuntu12.4 install jdk1.8 and ubuntu12.4jdk1.8

Ubuntu12.4 install jdk1.8

1. Copy the jdk to be installed to the shared folder.

(You can also copy data with a USB flash drive)

2. I copied jdk to the user folder.

(This can be done elsewhere, but the path must be changed accordingly)

3. Run the copy, install, and unzip command:

Decompress:

 

View the decompressed Folder:

4. Configure environment variables:

Write the following five lines of code:

Make the configuration take effect:

5. view the installed jdk:

Java-version

Java

Javac

6. You can also use the following command to modify the default jdk:

 

Sudo update-alternatives-install/usr/bin/java/usr/lib/jvm/jdk1.8.0 _ 25/bin/java300

 

Sudo update-alternatives-install/usr/bin/javac/usr/lib/jvm/jdk1.8.0 _ 25/bin/javac300

 

Sudo update-alternatives-config java

 


 

 

 

 

 

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.