You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by niblz <kr...@bgumail.bgu.ac.il> on 2007/10/03 10:28:33 UTC

Fresh install of Tomcat - getting frustrated with the JSP no working

Hello I have install a new fresh Tomcat 6, and I have JAVA 6 (all the newest
versions from their sites)
I have tried many things, but still while html and servlet work, JSP just
won't work!
I even tried using this Tomcat version and help - 
http://www.coreservlets.com/Apache-Tomcat-Tutorial/
http://www.coreservlets.com/Apache-Tomcat-Tutorial/ 
But still nothing
This are the errors I get
type Exception report message  description The server encountered an
internal error () that prevented it from fulfilling this request. exception 
org.apache.jasper.JasperException: Unable to compile class for JSP:  An
error occurred at line: 22 in the generated java fileThe method
getJspApplicationContext(ServletContext) is undefined for the type
JspFactory An error occurred at line: 82 in the generated java fileThe
method handlePageException(Exception) in the type PageContext is not
applicable for the arguments (Throwable) Stacktrace:   
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:92)   
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)   
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:423)   
org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)   
org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)   
org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)   
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)   
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)   
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)   
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)   
javax.servlet.http.HttpServlet.service(HttpServlet.java:865) note The full
stack trace of the root cause is available in the Apache Tomcat/6.0.14 logs

and this one
HTTP Status 500 - 
--------------------------------------------------------------------------------
type Exception report message  description The server encountered an
internal error () that prevented it from fulfilling this request. exception 
org.apache.jasper.JasperException: Unable to compile class for JSP:  
Stacktrace:   
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)   
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)   
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:415)   
org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)   
org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)   
org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)   
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)   
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:308)   
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)   
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)   
javax.servlet.http.HttpServlet.service(HttpServlet.java:865) note The full
stack trace of the root cause is available in the Apache Tomcat/6.0.10 logs.


What can I do please?

Thank you!

-- 
View this message in context: http://www.nabble.com/Fresh-install-of-Tomcat---getting-frustrated-with-the-JSP-no-working-tf4560454.html#a13014781
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Fresh install of Tomcat - getting frustrated with the JSP no working

Posted by niblz <kr...@bgumail.bgu.ac.il>.
Here is the JSP - just a very simple one 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 
<!-- 
Simple JSP file to test server setup and configuration. 
    
Taken from Core Servlets and JavaServer Pages 2nd Edition 
from Prentice Hall and Sun Microsystems Press, 
http://www.coreservlets.com/. 
(C) 2003 Marty Hall; may be freely used or adapted. 
--> 
<HTML> 
<HEAD><TITLE>JSP Test</TITLE></HEAD> 
<BODY BGCOLOR="#FDF5E6"> 
<H1>JSP Test</H1> 
Time: <%= new java.util.Date() %> 
</BODY></HTML> 

and this is the log file: 
03/10/2007 12:24:47 org.apache.catalina.core.StandardWrapperValve invoke 
SEVERE: Servlet.service() for servlet jsp threw exception 
org.apache.jasper.JasperException: Unable to compile class for JSP: 



Stacktrace: 
        at
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85) 
        at
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330) 
        at
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:415) 
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:308) 
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286) 
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:273) 
        at
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566) 
        at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:308) 
        at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320) 
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) 
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:865) 
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) 
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) 
        at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:228) 
        at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) 
        at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) 
        at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104) 
        at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) 
        at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:216) 
        at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) 
        at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:634) 
        at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:445) 
        at java.lang.Thread.run(Thread.java:619) 


What can I do please ?

-- 
View this message in context: http://www.nabble.com/Fresh-install-of-Tomcat---getting-frustrated-with-the-JSP-no-working-tf4560454.html#a13016034
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Fresh install of Tomcat - getting frustrated with the JSP no working

Posted by niblz <kr...@bgumail.bgu.ac.il>.
Man you are a genius!!!
Problem solved!
It seem I had a thing in my path, where an older version of some api's like
Servlet.api was casuing some mismatch!
Now Every thing work very nice!
Thank you guys :)


Larry Isaacs wrote:
> 
> If I recall correctly, in JSP spec 1.1, the argument for
> handlePageException() was Exception.  In JSP spec 1.2 and later, the
> argument is Throwable.  It would appear you have a servlet.jar from
> Servlet 2.2/JSP 1.1 somehow becoming the jar this JSP is running
> against, causing the method signature mismatch.  Make sure you don't
> have a copy of servlet.jar in the WEB-INF/lib of your webapp or
> somewhere else involved with the running server, such as in the
> lib/ext directory of your JDK or JRE.
> 
> In Tomcat 6, the JSP API classes are found in jsp-api.jar and servlet
> API classes are found in servlet-api.jar, with both located in the lib
> directory of the Tomcat 6 installation.  Any servlet.jar you find
> involved with this server would contain out of date classes for this
> server.
> 
> Cheers,
> Larry
> 
>> -----Original Message-----
>> From: niblz [mailto:krono@bgumail.bgu.ac.il]
>> Sent: Wednesday, October 03, 2007 4:29 AM
>> To: users@tomcat.apache.org
>> Subject: Fresh install of Tomcat - getting frustrated with the JSP no
>> working
>> 
>> 
>> Hello I have install a new fresh Tomcat 6, and I have JAVA 6 (all the
>> newest
>> versions from their sites)
>> I have tried many things, but still while html and servlet work, JSP
>> just
>> won't work!
>> I even tried using this Tomcat version and help -
>> http://www.coreservlets.com/Apache-Tomcat-Tutorial/
>> http://www.coreservlets.com/Apache-Tomcat-Tutorial/
>> But still nothing
>> This are the errors I get
>> type Exception report message  description The server encountered an
>> internal error () that prevented it from fulfilling this request.
>> exception
>> org.apache.jasper.JasperException: Unable to compile class for JSP:
> An
>> error occurred at line: 22 in the generated java fileThe method
>> getJspApplicationContext(ServletContext) is undefined for the type
>> JspFactory An error occurred at line: 82 in the generated java fileThe
>> method handlePageException(Exception) in the type PageContext is not
>> applicable for the arguments (Throwable) Stacktrace:
>>
> org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorH
>> andler.java:92)
>>
> org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.j
>> ava:330)
>>
> org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:4
>> 23)
>> org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)
>> org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
>> org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
>>
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
>> ava:566)
>>
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.j
>> ava:317)
>>
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320
>> )
>> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
>> javax.servlet.http.HttpServlet.service(HttpServlet.java:865) note The
>> full
>> stack trace of the root cause is available in the Apache Tomcat/6.0.14
>> logs
>> 
>> and this one
>> HTTP Status 500 -
>>
> -----------------------------------------------------------------------
>> ---------
>> type Exception report message  description The server encountered an
>> internal error () that prevented it from fulfilling this request.
>> exception
>> org.apache.jasper.JasperException: Unable to compile class for JSP:
>> Stacktrace:
>>
> org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorH
>> andler.java:85)
>>
> org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.j
>> ava:330)
>>
> org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:4
>> 15)
>> org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)
>> org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
>> org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
>>
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
>> ava:566)
>>
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.j
>> ava:308)
>>
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320
>> )
>> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
>> javax.servlet.http.HttpServlet.service(HttpServlet.java:865) note The
>> full
>> stack trace of the root cause is available in the Apache Tomcat/6.0.10
>> logs.
>> 
>> 
>> What can I do please?
>> 
>> Thank you!
>> 
>> --
>> View this message in context: http://www.nabble.com/Fresh-install-of-
>> Tomcat---getting-frustrated-with-the-JSP-no-working-
>> tf4560454.html#a13014781
>> Sent from the Tomcat - User mailing list archive at Nabble.com.
>> 
>> 
>> ---------------------------------------------------------------------
>> To start a new topic, e-mail: users@tomcat.apache.org
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Fresh-install-of-Tomcat---getting-frustrated-with-the-JSP-no-working-tf4560454.html#a13019854
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Fresh install of Tomcat - getting frustrated with the JSP no working

Posted by Larry Isaacs <La...@sas.com>.
If I recall correctly, in JSP spec 1.1, the argument for
handlePageException() was Exception.  In JSP spec 1.2 and later, the
argument is Throwable.  It would appear you have a servlet.jar from
Servlet 2.2/JSP 1.1 somehow becoming the jar this JSP is running
against, causing the method signature mismatch.  Make sure you don't
have a copy of servlet.jar in the WEB-INF/lib of your webapp or
somewhere else involved with the running server, such as in the
lib/ext directory of your JDK or JRE.

In Tomcat 6, the JSP API classes are found in jsp-api.jar and servlet
API classes are found in servlet-api.jar, with both located in the lib
directory of the Tomcat 6 installation.  Any servlet.jar you find
involved with this server would contain out of date classes for this
server.

Cheers,
Larry

> -----Original Message-----
> From: niblz [mailto:krono@bgumail.bgu.ac.il]
> Sent: Wednesday, October 03, 2007 4:29 AM
> To: users@tomcat.apache.org
> Subject: Fresh install of Tomcat - getting frustrated with the JSP no
> working
> 
> 
> Hello I have install a new fresh Tomcat 6, and I have JAVA 6 (all the
> newest
> versions from their sites)
> I have tried many things, but still while html and servlet work, JSP
> just
> won't work!
> I even tried using this Tomcat version and help -
> http://www.coreservlets.com/Apache-Tomcat-Tutorial/
> http://www.coreservlets.com/Apache-Tomcat-Tutorial/
> But still nothing
> This are the errors I get
> type Exception report message  description The server encountered an
> internal error () that prevented it from fulfilling this request.
> exception
> org.apache.jasper.JasperException: Unable to compile class for JSP:
An
> error occurred at line: 22 in the generated java fileThe method
> getJspApplicationContext(ServletContext) is undefined for the type
> JspFactory An error occurred at line: 82 in the generated java fileThe
> method handlePageException(Exception) in the type PageContext is not
> applicable for the arguments (Throwable) Stacktrace:
>
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorH
> andler.java:92)
>
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.j
> ava:330)
>
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:4
> 23)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
>
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
> ava:566)
>
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.j
> ava:317)
>
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320
> )
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:865) note The
> full
> stack trace of the root cause is available in the Apache Tomcat/6.0.14
> logs
> 
> and this one
> HTTP Status 500 -
>
-----------------------------------------------------------------------
> ---------
> type Exception report message  description The server encountered an
> internal error () that prevented it from fulfilling this request.
> exception
> org.apache.jasper.JasperException: Unable to compile class for JSP:
> Stacktrace:
>
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorH
> andler.java:85)
>
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.j
> ava:330)
>
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:4
> 15)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
>
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
> ava:566)
>
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.j
> ava:308)
>
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320
> )
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:865) note The
> full
> stack trace of the root cause is available in the Apache Tomcat/6.0.10
> logs.
> 
> 
> What can I do please?
> 
> Thank you!
> 
> --
> View this message in context: http://www.nabble.com/Fresh-install-of-
> Tomcat---getting-frustrated-with-the-JSP-no-working-
> tf4560454.html#a13014781
> Sent from the Tomcat - User mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Fresh install of Tomcat - getting frustrated with the JSP noworking

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Marty Hall [mailto:hall@coreservlets.com] 
> Subject: RE: Fresh install of Tomcat - getting frustrated 
> with the JSP noworking
> 
> Sorry if I was unclear. The part on setting the CLASSPATH was under 
> the section entitled "Setting up your Development Environment".

Part of the problem is the link to the CLASSPATH section from Executive
Summary.  When following that link, the fact that it's under the
Development Environment section can't be seen.  There needs to be a
stronger statement that setting CLASSPATH is *only* for compilation of
servlets, and that it must be removed prior to actually running Tomcat.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Fresh install of Tomcat - getting frustrated with the JSP noworking

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Marty Hall [mailto:hall@coreservlets.com] 
> Subject: RE: Fresh install of Tomcat - getting frustrated 
> with the JSP noworking
> 
> If you compile directly (from TextPad or UltraEdit or the 
> command line), then you need to either set the CLASSPATH
> variable or pass -classpath on the command line or put the 
> JARs in the ext folder (this is in the development environment, not 
> the server environment).

That is indeed correct.  However, the links within the tutorial indicate
that CLASSPATH should be set for the Tomcat server execution, not just
servlet compilation.  Including those jars in the CLASSPATH during
Tomcat execution causes multiple copies of the classes to be loaded
under different classloaders, resulting in no end of grief with CNFE
problems.  (Also, the given location of the jars is incorrect for Tomcat
6.)

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Fresh install of Tomcat - getting frustrated with the JSP noworking

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: niblz [mailto:krono@bgumail.bgu.ac.il] 
> Subject: Re: Fresh install of Tomcat - getting frustrated 
> with the JSP noworking
> 
> http://www.coreservlets.com/Apache-Tomcat-Tutorial/

At least part of that tutorial is fatally flawed, and the author should
be ashamed of himself.  One must *never* set CLASSPATH to include the
servlet-api.jar and jsp-api.jar (besides, he gave incorrect locations).
Get rid of the CLASSPATH - you don't need it.

> I have download this OFFICIAL example
> http://tomcat.apache.org/tomcat-6.0-doc/appdev/sample/

Works fine for me; where did you put it?

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Fresh install of Tomcat - getting frustrated with the JSP no working

Posted by niblz <kr...@bgumail.bgu.ac.il>.
O I have got mine from the offical Tomcat site, and other version from here
http://www.coreservlets.com/Apache-Tomcat-Tutorial/
Aa for copying things to my web-inf, well no
The only thing I have done is putting the JSP in the ROOT dir in the web-app
and trying to get into it
Also
I have download this OFFICIAL example
http://tomcat.apache.org/tomcat-6.0-doc/appdev/sample/
And nothing (and I am sure this VERY simple example should work with out any
problems)
What shell I do now please?



Pid-2 wrote:
> 
> Right.
> 
> Where did you get Tomcat 6 from, and what OS are you running?
> 
> Have you moved or copied any of the libraries from Tomcat/lib to your
> WEB-INF/lib?
> 
> p
> 
> 
> niblz wrote:
>> Here is the JSP - just a very simple one
>> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
>> <!-- 
>> Simple JSP file to test server setup and configuration. 
>>    
>> Taken from Core Servlets and JavaServer Pages 2nd Edition
>> from Prentice Hall and Sun Microsystems Press,
>> http://www.coreservlets.com/.
>> (C) 2003 Marty Hall; may be freely used or adapted.
>> -->
>> <HTML>
>> <HEAD><TITLE>JSP Test</TITLE></HEAD>
>> <BODY BGCOLOR="#FDF5E6">
>> <H1>JSP Test</H1>
>> Time: <%= new java.util.Date() %>
>> </BODY></HTML>
>> 
>> and this is the log file:
>> 03/10/2007 12:24:47 org.apache.catalina.core.StandardWrapperValve invoke
>> SEVERE: Servlet.service() for servlet jsp threw exception
>> org.apache.jasper.JasperException: Unable to compile class for JSP: 
>> 
>> 
>> 
>> Stacktrace:
>> 	at
>> org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)
>> 	at
>> org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)
>> 	at
>> org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:415)
>> 	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)
>> 	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
>> 	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
>> 	at
>> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)
>> 	at
>> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:308)
>> 	at
>> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
>> 	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
>> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
>> 	at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>> 	at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>> 	at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:228)
>> 	at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
>> 	at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
>> 	at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
>> 	at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>> 	at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:216)
>> 	at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
>> 	at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:634)
>> 	at
>> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:445)
>> 	at java.lang.Thread.run(Thread.java:619)
>> 
>> 
>> What can I do please ?
> 
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Fresh-install-of-Tomcat---getting-frustrated-with-the-JSP-no-working-tf4560454.html#a13019654
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Fresh install of Tomcat - getting frustrated with the JSP no working

Posted by Pid <p...@pidster.com>.
Right.

Where did you get Tomcat 6 from, and what OS are you running?

Have you moved or copied any of the libraries from Tomcat/lib to your
WEB-INF/lib?

p


niblz wrote:
> Here is the JSP - just a very simple one
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> <!-- 
> Simple JSP file to test server setup and configuration. 
>    
> Taken from Core Servlets and JavaServer Pages 2nd Edition
> from Prentice Hall and Sun Microsystems Press,
> http://www.coreservlets.com/.
> (C) 2003 Marty Hall; may be freely used or adapted.
> -->
> <HTML>
> <HEAD><TITLE>JSP Test</TITLE></HEAD>
> <BODY BGCOLOR="#FDF5E6">
> <H1>JSP Test</H1>
> Time: <%= new java.util.Date() %>
> </BODY></HTML>
> 
> and this is the log file:
> 03/10/2007 12:24:47 org.apache.catalina.core.StandardWrapperValve invoke
> SEVERE: Servlet.service() for servlet jsp threw exception
> org.apache.jasper.JasperException: Unable to compile class for JSP: 
> 
> 
> 
> Stacktrace:
> 	at
> org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)
> 	at
> org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)
> 	at
> org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:415)
> 	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)
> 	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
> 	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
> 	at
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)
> 	at
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:308)
> 	at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
> 	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> 	at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:228)
> 	at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
> 	at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
> 	at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
> 	at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> 	at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:216)
> 	at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
> 	at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:634)
> 	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:445)
> 	at java.lang.Thread.run(Thread.java:619)
> 
> 
> What can I do please ?


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Fresh install of Tomcat - getting frustrated with the JSP no working

Posted by niblz <kr...@bgumail.bgu.ac.il>.
Here is the JSP - just a very simple one
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- 
Simple JSP file to test server setup and configuration. 
   
Taken from Core Servlets and JavaServer Pages 2nd Edition
from Prentice Hall and Sun Microsystems Press,
http://www.coreservlets.com/.
(C) 2003 Marty Hall; may be freely used or adapted.
-->
<HTML>
<HEAD><TITLE>JSP Test</TITLE></HEAD>
<BODY BGCOLOR="#FDF5E6">
<H1>JSP Test</H1>
Time: <%= new java.util.Date() %>
</BODY></HTML>

and this is the log file:
03/10/2007 12:24:47 org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: Unable to compile class for JSP: 



Stacktrace:
	at
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)
	at
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)
	at
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:415)
	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)
	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
	at org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
	at
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)
	at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:308)
	at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:228)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
	at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:216)
	at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
	at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:634)
	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:445)
	at java.lang.Thread.run(Thread.java:619)


What can I do please ?
-- 
View this message in context: http://www.nabble.com/Fresh-install-of-Tomcat---getting-frustrated-with-the-JSP-no-working-tf4560454.html#a13015949
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Fresh install of Tomcat - getting frustrated with the JSP no working

Posted by David Smith <dn...@cornell.edu>.
Can we see the jsp you are trying to access?  Also check the logs for 
the very first exception in the request.  That will be the most helpful.

You can find the logs in tomcat's logs directory.

--David

niblz wrote:
> Hello I have install a new fresh Tomcat 6, and I have JAVA 6 (all the newest
> versions from their sites)
> I have tried many things, but still while html and servlet work, JSP just
> won't work!
> I even tried using this Tomcat version and help - 
> http://www.coreservlets.com/Apache-Tomcat-Tutorial/
> http://www.coreservlets.com/Apache-Tomcat-Tutorial/ 
> But still nothing
> This are the errors I get
> type Exception report message  description The server encountered an
> internal error () that prevented it from fulfilling this request. exception 
> org.apache.jasper.JasperException: Unable to compile class for JSP:  An
> error occurred at line: 22 in the generated java fileThe method
> getJspApplicationContext(ServletContext) is undefined for the type
> JspFactory An error occurred at line: 82 in the generated java fileThe
> method handlePageException(Exception) in the type PageContext is not
> applicable for the arguments (Throwable) Stacktrace:   
> org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:92)   
> org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)   
> org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:423)   
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)   
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)   
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)   
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)   
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)   
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)   
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)   
> javax.servlet.http.HttpServlet.service(HttpServlet.java:865) note The full
> stack trace of the root cause is available in the Apache Tomcat/6.0.14 logs
>
> and this one
> HTTP Status 500 - 
> --------------------------------------------------------------------------------
> type Exception report message  description The server encountered an
> internal error () that prevented it from fulfilling this request. exception 
> org.apache.jasper.JasperException: Unable to compile class for JSP:  
> Stacktrace:   
> org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)   
> org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)   
> org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:415)   
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)   
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)   
> org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)   
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)   
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:308)   
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)   
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)   
> javax.servlet.http.HttpServlet.service(HttpServlet.java:865) note The full
> stack trace of the root cause is available in the Apache Tomcat/6.0.10 logs.
>
>
> What can I do please?
>
> Thank you!
>
>   


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org