glassfish4.1.1 "A full JDK (not just JRE) is required" - glassfish-4.1.1

Windows 10: installed glassfish4.1.1 and jdk-8u111 but having the "A full JDK (not just JRE) is required" problem. The path variable looks ok as does the JAVA_HOME variable.

You need JDK not the JRE, JDK has the tools javac.exe, java.exe, jar.exe, etc.
Make sure you have downloaded JDK and set the PATH to point to the jdk/bin folder

Related

Issue with JDK installation

I have install JDK 8 kit.
I have set path variable to jdk bin
D:\Java\jdk1.8.0_181\bin
and home to jdk.
D:\Java\jdk1.8.0_181
I am able to see the version in cmd promt when I give java -version. But when I give javac - version its not able to find the jdk? Can anyone say what could be wrong?
On windows after installation (if no other java's are there) it should work out of the box - if not you should set JAVA_HOME to D:\Java\jdk1.8.0_181 and add JAVA_HOME\bin to the path. If you do so you have to restart any already open commandline - because they will not get the JAVA_HOME/PATH updates (if you did them via the windows system control).
You could test what java -version tells you first - to find out if a runtime environment is still referenced.

TFS2017 Code search configuration at TFS2017 Admin console

While configuring Search feature at TFS2017 admin console I am getting below error & configuration is getting failed. Although i have installed JDK 8.0 & server JRE8 update 20 & set the environment variable JAVA_HOME but still issue persists. Can someone help me out on this. Please suggest.
"Search requires Oracle Server JRE 7 Update 55 or higher, or JRE 8
Update 20 or higher, and a suitable version was not detected or is not
correctly configured on this computer. You can download and install
the latest version by accepting the Oracle Binary Code License
Agreement for Server JRE and selecting ‘Configure’. Note that this
will set the JAVA_HOME environment variable to point to the Java
installation directory, and that Server JRE does not provide automatic
updates. See Java installation notes for more information."
Serach Config Wizard screenshot
Please see Java installation notes for Code Search configuration, make sure you have set the environment variable correctly.
For example: as a variable name choose JAVA_HOME and as value set the path of the folder where JRE is installed, eg C:\Program Files\Java\jre1.8.0_11,
If the Search configuration wizard does not detect a working
installation of Java Server JRE, it provides an option to download and
install the latest version. Internet connectivity is required to
download this from the Java website. If the target server does not
have Internet connectivity, you must download and install Server JRE
manually before attempting to install Code Search.
During installation, the wizard sets the JAVA_HOME environment
variable to point to the Server JRE installation folder. The
configuration wizard may fail to detect an existing Server JRE
installation if it is not correctly configured, or if the
JAVA_HOME setting points to an earlier version than that required by Code Search.
If there is a version of Server JRE earlier than the minimum
required by Code Search, and the JAVA_HOME variable is set to that
version, we recommend you install Search on a separate server because
changing the value of the JAVA_HOME variable may cause other
installed software to fail.
If there is a version of Server JRE equal to or later than the
minimum required by Code Search, and it is not recognized by the
configuration wizard, you must set the value of the JAVA_HOME variable
to that version as described in the Java troubleshooting guide,
and then rerun the configuration wizard.
This looks like an intermittent issue for me. I had to get Azul openJDK8
and JAVA_HOME in Environment variable set to
"C:...\zulu8.54.0.21-ca-jdk8.0.292-win_x64\zulu8.54.0.21-ca-jdk8.0.292-win_x64\"

Glassfish installation JRE not found

I can't install Oracle Glassfish Server 3.1.2.2
When I run the installer (as admin) a dialog box appears saying "extracting files" and then I get the following error box saying I don't have JRE installed.
I have JRE and JDK 1.6 and 1.7 installed (all are 64 bit).
All are in the PATH system variable.
I've tried the program from CMD using the instructions in the error.
The command I use to run is:
OracleGlassfishServer(OGS)-3.1.2.2-windows.exe" -j "c:\Program Files\Java\jdk1.7.0_09\bin
I've also tried with the 1.6 bin.
I am running Win 7 64 bit.
The only thing I haven't thought to try yet was installing a 32bit JRE in the Program Files(x86) directory. Does it make sense that this would require a 32bit JRE?
What else could be the cause?
The Glassfish installation program requires the path to the JRE installation folder to be in the JAVA_HOME environment variable; if the variable is not set the folder can be specified on the command line. In both cases the folder must be the root folder of the JRE, not the bin subfolder.
Unfortunately, I found setting JAVA_HOME to be ineffective for me.
The solution that worked on my server was to run the Glassfish install with the -j option pointing to my JDK.
using command line and pointing to JRE installation directory should work Just fine, the problem with the above command is that you were pointing to bin directory, simply point to the home directory that is "c:\Program Files\Java\jdk1.7.0_09"

Requirement for setting JRE path in windows7, like setting path for JDK

Should I have to add/set the path for JRE as well like I did for JDK 1.7? If yes, then please explain how. If no then why it is not necessary. (I am using windows 7, 64 bit)
Thank you.
The "JDK" is the Java Development Kit. I.e., the JDK is bundle of software that you can use to develop Java based software.
The "JRE" is the Java Runtime Environment. I.e., the JRE is an implementation of the Java Virtual Machine which actually executes Java programs. Without JRE one can only compile the application but cannot run the application.
Since JRE contains the JVM which executes the byte code generated from the javac compiler, you need to add your JRE path to JAVA_HOME variable from the environment variables. Here's the tutorial for doing so: http://java.com/en/download/help/path.xml
Technically, the JDK contains the JRE, so if you have set your PATH properly you shouldn't need a separate entry for the JRE.
Think of it this way - the JRE contains everything you need to run a Java program. The JDK contains everything you need to run AND develop the program.

Error: Unable to locate tools.jar. Expected to find it in /usr/lib/jvm/java-6-sun-1.6.0.26/lib/tools.jar

I am trying to build jasperserver on linux. It uses ant and maven. While executing the ant command it gives this exception. I checked on the same path however the lib folder is not there at the same path. How can I resolve this issue?
Thanks!!
tools.jar is present only in jdk, not jre.
I have fixed this issue by installing jdk..
Thanks to all for reply ..
I saw the same message running Ant after a JVM update. I fixed it by setting JAVA_HOME to JDK.
It could be that your eclipse is defaulting to your 32bit version of your jre. If you do everything right with JAVA_HOME set to C:\Program Files\Java\jdk1.6.0_21\bin and your running a 32bit version of eclipse you'll end up using something like C:\Program Files (x86)\Java\jre6\bin.
once you fix your jdk issue You will need to pass it on the end of a shortcut -vm "C:\Program Files (x86)\Java\jdk1.6.0_31\bin"
Or fix your JAVA_HOME
Other suggestions have been to make sure your eclipse is using the jdk not jre http://gamefromscratch.com/post/2011/11/15/Telling-Eclipse-to-use-the-JDK-instead-of-JRE.aspx
Just for others reference:By default eclipse will point to jre not jdk. if you want to change default jre please got to
window -> Preferences -> Java -> Installed JREs
click on add button select Standanrd VM then set JRE home.
here you can provide your installed jdk path it will look like below in case of windows.
C:\Program Files\Java\jdk1.8.0_101

Resources