As the title says, the solution is as follows.
Execute the following command
C:\Users\test>set JAVA_HOME
C:\Users\test>where java
If the following is displayed, a file with a name such as Java 6 Update 45
is installed, so uninstall it.
C:\Users\test>set JAVA_HOME
JAVA_HOME=C:\Program Files\Java\jdk1.7.0_21
C:\Users\test>where java
C:\Windows\System32\java.exe
C:\Program Files\Java\jdk1.7.0_21\bin\java.exe
When you restart your PC and execute the following command, C: \ Windows \ System32 \ java.exe
should be deleted.
C:\Users\test>where java
C:\Program Files\Java\jdk1.7.0_21\bin\java.exe
Now when you run java -version
, the JDK set in JAVA_HOME will be loaded correctly.
C:\Users\test>java -version
java version "1.7.0_21"
Java(TM) SE Runtime Environment (build 1.7.0_21-b11)
Java HotSpot(TM) 64-Bit Server VM (build 23.21-b01, mixed mode)
Unless it is a major update such as language version upgrade after building the environment once You don't need to have the updater installed, as you probably won't update the JDK.
-Official Java 6 update finished -April 2013 Alert Regarding Critical Patch Update (Regular) of Oracle Java SE (JPCERT / CC)
Recommended Posts