maybe a clarification of the process will help. it’s all very simple stuff, really.
every Java Runtime Environment (JRE) ships with an executable program named “java” (e.g. java.exe in Windows). in order to run a Java program, like Catalina in this case (which is the servlet container component of Tomcat, that in turn runs Lucee), you need to call the java executable and point to the java program’s main entry point. (a slight variation when running as a service, where you reference the jvm.dll as opposed to the java executable).
so now the paths come into play.
most batch (and shell) scripts that ship with java programs don’t know where the JRE/bin is installed, so it’s become the standard way of using environment variables like JAVA_HOME (points to the JDK) and JRE_HOME (points to… well… the JRE). then the script does something like that (pseudo-cfscript-code):
so in your case modifying the batch script and removing “directory” prefix before the “java” call would have been sufficient.
if we need to improve the scripts, we will do it as soon as possible once we find the problems (user reporting is the best way for us to find problems).
p.s. if you have the JRE’s bin directory in your system classpath, you can simply call “java”, as you did when you tried “java -version” and got the JRE to report its version (if you hadn’t had the bin directory in your system classpath you would have gotten an error).
Yes, the JDK that the system JAVA_HOME var points to contains a JRE. I’ve also tried pointing JAVA_HOME directly at the jre dir, in startup.bat, no joy. Only thing that has worked so far is setting JRE_HOME to point there, in startup.bat.
Just to note, the system environment var JAVA_HOME already points to the same JDK, and works for other apps.
Dave
On Thursday, February 5, 2015 at 10:49:26 PM UTC-5, mmm mmm wrote:
O.K. when you installed jdk did you also install the public jre? If so everything should have worked fine,
if you did not install the public jre there still is a jre in the jdk folder,
tomcat needs to be pointed to that jre, like I posted earlier which seems to be the correct way after checking with some tomcat forums.
4 Ways to Change JRE for Tomcat
On Thursday, February 5, 2015 at 5:55:33 AM UTC-6, Dave Merrill wrote:
Thanks for jumping in Igal.
Echoing JAVA_HOME, it points to a Java 1.7 JDK, valid and used by multiple ACF and Railo instances on this box without problems. Java version reported is 1.7.0_75, which as I understand it is fine.
I’m sorry guys (not you specifically Igal), but these various responses are still totally unclear to me. On one level it doesn’t matter to me, since I’m up and running after setting JDK_HOME in startup.bat and shutdown.bat, but in terms of making it clear to others with similar problems what they should do, we’re not there yet.
To quote myself, this is my as-yet-unconfirmed-by-the-community hypothesis:
a) If you do have JAVA_HOME pointing to a valid JDK with a supported version and still have this problem, try setting JDK_HOME in startup.bat (and shutdown.bat)
b) There will be a new build at some point that will make that step unnecessary
Is that right?
I’m not trying to be difficult, or critical of anyone, just trying to leave clear, unambiguous info for anyone who just wants this to work.
Thanks,
Dave
On Wednesday, February 4, 2015 at 6:46:32 PM UTC-5, igal wrote:
yes, “Unsupported major.minor version 51.0” is a Java version. 51 is Java 7.
Lucee does not require Java 8 to run, no.
what do you see if you go to a command line and you run the following two commands:
echo %JAVA_HOME%
java -version
?
On 2/3/2015 7:27 AM, Dave Merrill wrote:
Thanks Mark, that was at least partially helpful. I did see an error running it that way, which I’ll try to retype here; tried to pipe the result to a file, but it just echoed the environment vars, not the error.
Exception in thread “main” java.lang.UnsupportedClassVersionErrror: org/apache/catalina/startup/Bootstrap : Unsupported major.minor version 51.0
Could not find the main class org.apache.catalina.startup.Bootstrap. Program will exit.
Is this about supported Java versions? If so, and I need to install Java 1.8, but don’t want to change the system environment var, where should I set JAVA_HOME so Luceee sees it? Directly in startup.bat? Some config?
Thanks again,
Dave
On Tuesday, February 3, 2015 at 9:36:18 AM UTC-5, Mark Drew wrote:
Hi Dave
In the command line do the following
cd lucee
cd bin
catalina.bat run
That should give you all the output
otherwise just open up lucee/logs/catalina.out and that will tell you what is happening at startup
Regards
Mark Drew
On 3 Feb 2015, at 14:33, Dave Merrill enig...@gmail.com wrote:
I have Java 1.7 installed, and the system environment var JAVA_HOME points to it.
-
Does Lucee actually require 1.8? Where are the system requirements documented?
-
Do I need to set JAVA_HOME somewhere in the Lucee startup script or configs, or is the system var sufficient?
Dave
On Tuesday, February 3, 2015 at 8:58:49 AM UTC-5, Adam De Lay wrote:
Dave,
I had the same problem you did initially. I’m running on Win 8.1 and when I tried to run startup.bat, it opened and closed. What I found out was that I needed to have installed (I believe) JRE 1.8 and set the JAVA_HOME env var. Once I had that installed, then I retried running the startup.bat and it ran and opened a new command window (Tomcat) but when I looked at the log file, there was still some problem (I believe it was a binding issue because of how many times I had tried running the startup.bat). I rebooted and then everything came up as it should when I ran the batch file.
Hopefully that helps.
Adam De Lay
On Tuesday, February 3, 2015 at 8:16:12 AM UTC-5, Dave Merrill wrote:
Please excuse my unfamiliarity with the underpinnings of the express version, but for me, it doesn’t “just run” (Win7 Pro). The included docs seem to be for some of the components used, not this package as a whole, and don’t appear to address potentially necessary configuration issues. Is this supposed to work now?
I know it’s early, not everything is soup yet, no criticism is intended, just want to get it running, and maybe help others who want the same. Maybe more familiarity with this infrastructure is assumed, but ideally, anyone could download the express package and be up and running with nothing but the instructions provided. At minimum, if configuration or environment setup is required, a Lucee-specific start-from-zero guide should be provided. Better error messaging would be great too.
Here’s what happens here: When I just double click startup.bat, it just exits, probably expected, but if so, should be documented somewhere. If I run it from the cmd line, it reads out some environment vars, then returns to the cmd prompt, without actually starting the Lucee engine, or complaining about why it couldn’t, as far as I can tell. Ran the cmd prompt as admin, no difference. The logs directory is empty.
Nothing in startup.bat appears to be machine or environment-specific, and nothing in web.xml, context.xml, or server.xml jumped out at me as needing to be edited.
Thanks for any thoughts, and again, my apologies for not knowing whatever is it that probably should be obvious to folks with more Java background. I’ve been working in CFML for many years, but clearly I’m missing some required info, and I’m quite likely not alone in that.
Dave
–
You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/b1da3fb3-65f0-47ba-b76c-c9ec783c370c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
–
You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/577801b5-7e60-4ec4-85a2-427dd114f8f2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
–
You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/f582db63-eb8f-4621-9484-5efa4d5a61e7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.