I\'ve got GlassFish 2.1.1 installed. I have a 1.5 and a 1.6 JDK installed. Even though my JAVA_HOME variable is set to the 1.5 version (and both \"java -version\" and \"java
Similar error with Glassfish 4.0 and several JDK installed:
SEVERE: GlassFish requires JDK 7, you are using JDK version 6.
There is no AS_JAVA reference in "C:\glassfish\config\asenv.bat" by default. After adding manually
set AS_JAVA=C:\Program Files\Java\jdk1.7.0_25
it works.