Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

To Tomcat and JSP users.. *help* :)

 
Ryan Yeap
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I recently installed tomcat on win98 and it worked alright. It displayed the defulat page and everything but when i tried to run a .jsp page, this error shows up. It works with the server in school but not at home. This is the error
"Error: 500
Location: /factorise.jsp
Internal Servlet Error:
java.lang.NoSuchMethodError
at org.apache.tomcat.context.ExceptionHandler.doService(DefaultCMSetter.java:289)
at org.apache.tomcat.core.Handler.service(Handler.java:287)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:1160)
at org.apache.tomcat.core.Handler.service(Handler.java:312)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:213)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
at java.lang.Thread.run(Thread.java:484)
"
There must be something that I havent configured properly but i can't seem to figure out what exactly. If you think you know the answer, just reply. I'll try EVERY answer. Thanks in advance
Ryan
 
Simon Brown
sharp shooter, and author
Ranch Hand
Posts: 1913
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It might be worth pasting in your JSP page so we can take a quick look.
Simon
------------------
Simon Brown
Author of Professional JSP 2nd Edition
 
Ashutosh Uprety
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ur jsp is giving a nosuchmethoderror.
it means that there is something wrong with some method u r calling.
look into the exception once again. it will give some more details in the lower part of the exception which seems to be a repetition of the top part. The exact error can be found out from there.
perhaps u could paste the whole exception page and then we can figure out something.
 
Ryan Yeap
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well this is the whole exception page. I think it's the same as what i posted above
----------------------------------------------------------------
Error: 500
Location: /prac1ques2.jsp
Internal Servlet Error:
java.lang.NoSuchMethodError
at org.apache.tomcat.context.ExceptionHandler.doService(DefaultCMSetter.java:289)
at org.apache.tomcat.core.Handler.service(Handler.java:287)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:1160)
at org.apache.tomcat.core.Handler.service(Handler.java:312)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:213)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
at java.lang.Thread.run(Thread.java:484)
-----------------------------------------------------------------
As for the code. Even the default ones. ( you know the ones that came when you first installed TomcaT?) Yeah they, too gave the same error.... but here it is anyway.
-----------------------------------------------------------------
<%-- A simple Date item! --%>
<%@ page import="java.util.*" %>
<html>
<head>
<title>
<%= new Date() %>
</title>
</head>
<body>
<%= new Date() %>
</body>
</html>
----------------------------------------------------------------
I seriously doubt its the code Some other configuration? My JDK? I'm using jdk1.3 ....
Thanks for the quick reply! Amzing! I just had dinner after posting the question
 
Ryan Yeap
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Anyone? I'm using Win98 ...
 
Simon Brown
sharp shooter, and author
Ranch Hand
Posts: 1913
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which version of Tomcat are you using? Also, make sure that your CLASSPATH is not set when you start up Tomcat.
------------------
Simon Brown
Author of Professional JSP 2nd Edition
 
Ryan Yeap
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ahh. I was using Tomcat 3.2.2
Its working fine now
-I removed the SET CLASSPATH ... from autoexec.bat
-I downloaded and installed JDK 1.3.1 (previously was 1.3[maybe there was an installation problem on my part)
- now it works perfect!
Thanks everyone for your help!
Thank you Simon
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic