Install the jdk ------- * .tar.gz package on Ubuntu

Source: Internet
Author: User
To install the jdk ------- * .tar.gz package on Ubuntu, first decompress * .tar.gz. the specific method is tar-xzvf * .tar.gz. assume that the folder obtained is java and the command to move it to/usr/is: sudomvjava/usr/then set the environment variable: sudogedit/etc/prof... to install the jdk ------- * .tar.gz package on Ubuntu, first decompress * .tar.gz. the specific method is tar-xzvf * .tar.gz. assume that the folder obtained is java and the command to move it to/usr/is: sudo mv java/usr/and then set the environment variable: sudo gedit/etc/profile before opening the file umask 022 at the end, enter: JAVA_HOME =/usr/java export JRE_HOME =/usr/java/jre export CLASSPATH =.: $ JAVA_HOME/lib : $ JRE_HOME/lib: $ CLASSPATH export PATH = $ JAVA_HOME/bin: $ JRE_HOME/bin: $ PATH modify the default jdk update-alternatives in Ubuntu -- install/usr/bin/java/usr/java/bin/java 300update-alternatives -- install/usr/bin/javac/usr/ java/bin/javac 300 adds the installed jdk to the java menu through this step. Update-alternatives -- config java: Select the default jdk java-version
Related Article

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.