First Java environment variable configuration

Source: Internet
Author: User

I. Download and install the JDK

1. JDK: http://www.oracle.com/technetwork/java/javase/downloads/index.html, the entry screen shows the latest JDK version.

2. After the tag is clicked, choose to accept their agreement and download the corresponding file according to your own system.

3. If you do not want to download the latest version of the JDK, then how to download the old version? Go to the JDK download page, scroll to the bottom of the page and have a Java archive that collects all the historical versions of the JDK.

Second, the environment variable configuration

1. Two installation prompts will appear during the installation of the install directory. The first time is to install the JDK, and the second is to install the JRE. It is recommended that all two are installed in a different folder in the same Java folder. The installation to remember the path they installed, I remember the first time I installed, because I did not pay attention to the next step, and finally in the configuration environment variable when not know where to install, and re-installed again.

2. Configure environment variables after installing JDK computer → properties → advanced system settings → environment variables

3. System variables → new java_home variable. Variable value fill in the JDK's installation directory (that's what I'm suggesting to remember, mine is E:\JAVA\jdk\jdk1.7.0_21).

4. System variable → look for Path variable → edit, enter%java_home%\bin at the value of the variable (note that the value of the variable at the end of the path has no; number, if not, first enter; number and then enter the above code)

There is a network to configure the classpath, but since jdk1.5, there is no need to configure classpath, so we have the Java environment variable is configured well, the rest is to verify that the installation is successful.

Third, test installation success

My operating system is windows, verify the installation is successful: Run cmd-> input java-> input javac, if two commands appear a lot of characters, then congratulations on your installation success, if it appears as shown:

So the JDK is not installed successfully, check is not which step out of the problem.

First Java environment variable configuration

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.