win10: JDK12.0.1 environment variable configuration

  1. Download and install (omitted)
  2. Configure environment variables (admin/system)

Anyway, the method is the same. The path I installed is: D:\Java\jdk-12.0.1

To configure system variables, configure JAVA_HOME and Path in this part

JAVA_HOME : D:\Java\jdk-12.0.1 

Path: Add: %JAVA_HOME%\bin

To configure administrator variables, configure JAVA_HOME and Path in this part

JAVA_HOME : D:\Java\jdk-12.0.1 

Path: Add: %JAVA_HOME%\bin

Among them, the configuration location of these two variables is to create a new JAVA_HOME in the Administrator box and add it after Path.

After the configuration is completed, test: win+R -> java -version When you see the following information, it means ok

Note: (1) Do not create a new JAVA_HOME in the Administrator variable, and then add %JAVA_HOME%\bin after the Path of the system variable.

           (2) %JAVA_HOME%\bin should not be written as %JAVA_HOME\bin

Guess you like

Origin blog.csdn.net/songxiaolingbaobao/article/details/89914683