Linux Configuration 2-installing JDK in VMware

Source: Internet
Author: User

1. Copy the file jdk-7u79-linux-x64.tar.gz to the/tmp directory through the shared folder

CP jdk-7u79-linux-x64.tar.gz/tmp

2. Unzip the file

TAR-ZXVF jdk-7u79-linux-x64.tar.gz

3. Setting up the directory sudo MKDIR/USR/LIB/JVM

5. Move the extracted files to the JVM below MV jdk1.7.0_79/usr/lib/jvm/

6. Configure Environment variables

/usr/lib/jvm/jdk1.7.0_79$ VI ~/.BASHRC

You can also use Gedit/usr/lib/jvm/jdk1.7.0_79$sudo gedit ~/.BASHRC

At the end of the document, add:

#jdk 1.7
Export java_home=/usr/lib/jvm/jdk1.7.0_79
Export JRE_HOME=${JAVA_HOME}/JRE
Export Classpath=.:${java_home}/lib:${jre_home}/lib
Export Path=${java_home}/bin: $PATH

Save exit

Java--version Check if OK

Linux Configuration 2-installing JDK in VMware

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.