wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes Windows 7 64 bit Juno 4.2 java 7 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Windows 7 64 bit Juno 4.2 java 7" Watch "Windows 7 64 bit Juno 4.2 java 7" New topic
Author

Windows 7 64 bit Juno 4.2 java 7

Michael Sampson
Ranch Hand

Joined: Sep 24, 2008
Posts: 30
So I shall skip all the history behind this question and do my best to diagnose the problem and as a group, maybe we all can come up with a solution. I am a bit surpised I am posting this. I would have thought I would have figured this out on my own. I am putting this question in beginning java because it is an install issue I believe. So trouble started when I tried to set up Eclipse Juno 4.2. I get the 'Could not open JAVA_HOME\lib\amd64\jvm.cfg' error. I search around and what is happening is I hava 64 bit operating system (Windows 7), I have the 64 bit eclipse application, and now I need the 64 bit JRE. I need the full JDK which comes with a JRE so I figure, this is a great opportunity to upgrade to Java 7, the 64 bit version. I now have gone out and downloaded it and installed it. I changed the JAVA_HOME variable to the new path. The PATH variable builds off JAVA_HOME. I also found out, when checking java from the command line on windows 7 on 64 bit, you need the 64 bit command window. Typing 'cmd' into the start menu was not working. So here is what my DOS window looks like right now. I copied and pasted into the form.

C:\Java\java7_64b\jre\bin>java -version
java version "1.7.0_07"
Java(TM) SE Runtime Environment (build 1.7.0_07-b11)
Java HotSpot(TM) 64-Bit Server VM (build 23.3-b01, mixed mode)

C:\Java\java7_64b\jre\bin>cd ..

C:\Java\java7_64b\jre>java -version
java version "1.6.0_30"
Java(TM) SE Runtime Environment (build 1.6.0_30-b12)
Java HotSpot(TM) Client VM (build 20.5-b03, mixed mode)

C:\Java\java7_64b\jre>set path
Path=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32
\WindowsPowerShell\v1.0\;c:\Java\java7_64b\jre\bin;C:\maven2\bin\;c:\Gradle\bin;
c:\ant\bin
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC

C:\Java\java7_64b\jre>set java_home
JAVA_HOME=c:\Java\java7_64b

C:\Java\java7_64b\jre>

So this is fascinating. Clearly JAVA_HOME has the path to 64 bit Java 7 and when in the bin directory it indicates it is there however, when I pull up the DOS window I am defaulting to a different version of java I still have on the machine. To get a DOS window that even does anything, I have to launch from the 64 bit windows directory which is different from all the System32 directories. So I am wondering is it a Windows 7 secuirty/user problem? Am I still pointing to a 32 bit environment? Do I have something misspelled somewhere? Do I have to formally go and uninstall the previous version of java? I am thinking if I can get this machine, default pointing to Java 7 64bit, then I will be able to launch Eclipse 64 bit Juno 4.2 without the error message coming up.Thanks in advance for actually reading this post.

Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 13884
    
  10

Try putting your Java 7 installation directory c:\Java\java7_64b\jre\bin at the beginning of the path, instead of somewhere in the middle.

There's probably a java.exe in one of the Windows system directories that points to your 32-bit Java 6 installation.

If you're using the JDK, you should not put the bin directory of the included JRE in the path, but the bin directory of the JDK itself, otherwise you cannot use the compiler (javac) from the command line.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Windows 7 64 bit Juno 4.2 java 7
 
Similar Threads
Java -Version Problem
"cannot resolve symbol" error when compiling...
Issue with JAVA_HOME setup
Trouble installing JDK 7
Passing Files in Web Services