User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the JSP section within the Web Development category of DaniWeb, a massive community of 401,707 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,895 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our JSP advertiser: Lunarpages JSP Web Hosting
Views: 5916 | Replies: 4
Reply
Join Date: Feb 2006
Posts: 9
Reputation: k_satish0101 is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
k_satish0101 k_satish0101 is offline Offline
Newbie Poster

Help tomcat5.0 server encountering a internal error while using jsp

  #1  
Feb 27th, 2006
getting the follg error after installing
tomcat5.0, jre, j2se and ms-access


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

org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:97)

org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:346)

org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:414)

org.apache.jasper.compiler.Compiler.compile(Compiler.java:472)

org.apache.jasper.compiler.Compiler.compile(Compiler.java:451)

org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)

org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:295)

org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)

org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)

javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
root cause
Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK

org.apache.tools.ant.taskdefs.compilers.CompilerAdapterFactory.getCompiler(CompilerAdapterFactory.java:106)

org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:935)

org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:764)

org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:382)

org.apache.jasper.compiler.Compiler.compile(Compiler.java:472)

org.apache.jasper.compiler.Compiler.compile(Compiler.java:451)

org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)

org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:295)

org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)

org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)

javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
note The full stack trace of the root cause is
available in the Apache Tomcat/5.0.28 logs.

Apache Tomcat/5.0.28

i'm occuring this following when i acess my jsp file

plz help me in this regards

thank u in advance
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Feb 2006
Posts: 1,375
Reputation: masijade is a jewel in the rough masijade is a jewel in the rough masijade is a jewel in the rough masijade is a jewel in the rough 
Rep Power: 8
Solved Threads: 120
masijade's Avatar
masijade masijade is online now Online
Nearly a Posting Virtuoso

Re: tomcat5.0 server encountering a internal error while using jsp

  #2  
Mar 1st, 2006
Originally Posted by k_satish0101
root cause
Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK

Have you actually checked your setenv/catalina script to
ensure that the variable JAVA_HOME points to a JDK
(i.e. /usr/java) or to a jre (i.e. /usr/java/jre). If your
JAVA_HOME variable points to a jre, then there is no javac
(as the error message says) to use inorder to compile the
jsp.
Reply With Quote  
Join Date: Feb 2006
Posts: 9
Reputation: k_satish0101 is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
k_satish0101 k_satish0101 is offline Offline
Newbie Poster

Re: tomcat5.0 server encountering a internal error while using jsp

  #3  
Mar 1st, 2006
Originally Posted by masijade
Have you actually checked your setenv/catalina script to
ensure that the variable JAVA_HOME points to a JDK
(i.e. /usr/java) or to a jre (i.e. /usr/java/jre). If your
JAVA_HOME variable points to a jre, then there is no javac
(as the error message says) to use inorder to compile the
jsp.
thank u for ur response
may i need to install jdk to avoid this error
Reply With Quote  
Join Date: Feb 2006
Posts: 9
Reputation: k_satish0101 is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
k_satish0101 k_satish0101 is offline Offline
Newbie Poster

Re: tomcat5.0 server encountering a internal error while using jsp

  #4  
Mar 1st, 2006
thank u for ur response
may i need to install jdk to avoid this error
Reply With Quote  
Join Date: Feb 2006
Posts: 1,375
Reputation: masijade is a jewel in the rough masijade is a jewel in the rough masijade is a jewel in the rough masijade is a jewel in the rough 
Rep Power: 8
Solved Threads: 120
masijade's Avatar
masijade masijade is online now Online
Nearly a Posting Virtuoso

Re: tomcat5.0 server encountering a internal error while using jsp

  #5  
Mar 2nd, 2006
If all you have is a jre, then yes, you need to install a jdk. Servlets will work
without a jdk as they are compiled before tomcat ever sees them. JSP pages,
on the other hand, are translated into java classes/files and then compiled by
tomcat the first time they are accessed, or the first time they are accessed
after having been changed since the last time it was compiled. Tomcat cannot
do this unless it has access to a compiler (javac). It only has this if a jdk is
installed and JAVA_HOME points to the jdk, not the jre (which is also included in
the jdk as a jre subdirectory).
Java Programmer and Sun Systems Administrator

----------------------------------------------

Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.
--Brian Kernighan
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb JSP Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Similar Threads
Other Threads in the JSP Forum

All times are GMT -4. The time now is 8:41 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC