CentOS Installation Jdk-8u111-linux-x64.tar.gz method

Source: Internet
Author: User

① First download the jdk-8u111-linux-x64.tar.gz JDK package on the window host side

② created under #cd/var/ftp/pub: #mkdir ProgramFiles folder

③ using FTP to upload window jdk.tar.gz to ProgramFiles folder

④ View: #cd/var/ftp/pub/programfiles whether to put in

⑤ Unpacking the installation package: #sudo tar -zxvf jdk-8u72-linux-x64.tar.gz

⑥ creating a Java directory in #cd/usr

⑦ move to unpack the package into my own custom installation directory: #mv jdk1.8.0_111/ /usr/java/

⑧ Configuring Environment variables:

    • Edit Config file: #sudo vim /etc/profile
    • At the tail of the file, add the following:
        java_home=/usr/java/jdk1.8.0_72  jre_home= $JAVA _home/jre  path= $PATH: $JAVA _home/bin  classpath=.:$ Java_home/lib/dt.jar: $JAVA _home/lib/tools.jar export  java_home export  jre_home export  PATH  Export CLASSPATH
    • To execute a command, refresh the configuration (Prerequisite action): #source /etc/profile
    • Check if the latest jdk:# is usedjava -version(#java或#javac)

CentOS Installation Jdk-8u111-linux-x64.tar.gz method

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.