What are the differences between java -version
and java -fullversion
?
The two do not seem to line up on my machine.
C:\Users\kmort>java -fullversion
java full version "1.8.0_20-b26"
C:\Users\kmort>java -version
java version "1.8.0_25"
Java(TM) SE Runtime Environment (build 1.8.0_25-b18)
Java HotSpot(TM) 64-Bit Server VM (build 25.25-b02, mixed mode)
This link (at the bottom) seems to indicate that fullversion
simply includes the build number. If that's true, what to I end up with a different answer when I run the two?
Note that this documentation neglects to refer to fullversion
entirely.
I am running on 64 bit Windows 7. If it helps, here is a screenshot of the JDK and JRE installs I have on my machine.
Update
When I run Window's where
command, I get the following:
C:\Users\kmort>where java
C:\Windows\System32\java.exe
C:\ProgramData\Oracle\Java\javapath\java.exe
C:\Program Files\Java\jdk1.8.0_25\bin\java.exe
The problem is with the java.exe
located in System32
. If I rename that one to something else, things work as expected. And the Oracle one is just symbolic links to the last one.
So now the question is why does this happen with a java.exe
in my System32
folder? (My endgame will be to delete java.exe
from the System32
folder, but I'd like to understand what's going on first.)
Update 2
Using Process Monitor, I can see that when I run either command on the offending C:\Windows\System32\java.exe
this is the executable that is run (see the screenshot of it calling LoadImage
on C:\Windows\System32\java.exe
). There are also a few references to C:\Windows\SysWOW64\java.exe
in both of them. I'm not sure why.
Also note that it appears my registry is correct. Currentversion is 1.8.
One other note, the timestamp on C:\Windows\System32\java.exe
is on a day that I know I installed a JRE.