Compile tomcat 4 problems

dear all pro,
i am compiling tomcat 4.1.24 (using JDK 1.4.2), now almost the final
stage but some errors found...
the errors all are produced by "jasper2", it said it cannot find the
javax.servlet....
In fact jasper2 also a source distribution, i try to compile it first
but same errors occurred as above...
do u have any idea about it? thanks your attention... ^_^
beachboy

Errors messages like this...thanks..^^
[javac] Compiling 79 source files to /usr/local/jakarta-tomcat-4.1.24-src/jasper/build/shared/classes
[javac] /usr/local/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/compiler/BeanRepository.java:72: package javax.servlet does not exist
[javac] import javax.servlet.ServletException;
[javac] ^
[javac] /usr/local/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/JasperException.java:70: package javax.servlet does not exist
[javac] public class JasperException extends javax.servlet.ServletException {
[javac] ^
[javac] /usr/local/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/JspCompilationContext.java:68: package javax.servlet does not exist
[javac] import javax.servlet.ServletContext;
[javac] ^
[javac] /usr/local/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/JspCompilationContext.java:69: package javax.servlet.jsp.tagext does not exist
[javac] import javax.servlet.jsp.tagext.TagInfo;

Similar Messages

  • JSP and Tomcat Problem

    Folks,
    My apologies if this is off-topic for this forum, but I've been having this problem using Tomcat and JSP. I'm fairly new to Java.
    Basically, I'm writing a webapp that uses servlets and JSP together. The servlet and backend classes all compile fine. Now, basic frontend page is called Console.jsp, and one of the commands that it runs is <%@ page import="DJUser">
    Here's the problem: Console.jsp is in $CATALINA_HOME/webapp/
    DJUser (and the rest of the classes I'm using) are in $CATALINA_HOME/webapp/WEB-INF/classes
    When I attempt to run Console.jsp I get this error:
    exception
    org.apache.jasper.JasperException: Unable to compile class for JSP
    Generated servlet error:
    The import DJUser cannot be resolved
    An error occurred at line: 9 in the jsp file: /Console.jsp
    Generated servlet error:
    DJUser cannot be resolved to a type
    An error occurred at line: 11 in the jsp file: /Console.jsp
    Generated servlet error:
    user cannot be resolved
    An error occurred at line: 11 in the jsp file: /Console.jsp
    Generated servlet error:
    DJUser cannot be resolved to a type
         org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
         org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
         org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:409)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:288)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
    The ROOT CAUSE is listed as:
    java.lang.ClassNotFoundException: org.apache.jsp.Console_jsp
         java.net.URLClassLoader$1.run(URLClassLoader.java:200)
         java.security.AccessController.doPrivileged(Native Method)
         java.net.URLClassLoader.findClass(URLClassLoader.java:188)
         org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:133)
         org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:65)
         org.apache.jasper.JspCompilationContext.load(JspCompilationContext.java:596)
         org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:137)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:305)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
    I'm running Tomcat 5.5.12 on Mac OS X 10.4. Could this be a permissions issue somehow? For right now (testing purposes only) I have tomcat running under my (non root) account.
    I've been scouring the web for a while, and I can't really find anything on this. I'd appreciate any help you could give me.
    Thanks!
    Dylan

    Put the DJUser java file in a package (say com.myClasses) and recompile. Then put the DJUser class file under the WEB-INF/classes directory in the proper package structure (WEB-INF/classes/com/myClasses/DJUser). Stop and restart the server to pick up the new classes. Make sure to change the jsp import statement ( <%@ page import="com.myClasses.DJUser">)

  • From resin to Tomcat Problems

    Hi everybody,
    I really need your expertise and help!!!
    We had a server using resin, then they decided to move the application to Tomcat.
    The server admin moved every thing by basically coping the JSP and JAVA files over.
    Then he stopped working on it and they gave it to me :-(
    and of course I have no expereince with this (No clue)
    I managed to get the connection to the database with help from the web.
    My problem is that I have two packages (mdx and sto) Both on the same level under classes folder.
    (They CANNOT see each other) convertFunctions.java Class is in mdx package
    ******************Part of the error ********************
    # javac convertFunctions.java
    convertFunctions.java:3: package sto does not exist
    import sto.*;
    ^
    convertFunctions.java:12: package javax.mail does not exist
    import javax.mail.*;
    ^
    convertFunctions.java:13: package javax.mail.internet does not exist
    import javax.mail.internet.*;
    ^
    When I run the page on the we I get this error
    "Error: HTTP Status 500 -" (It cannot see the methods inside the class)
    convertMenus is inside convertFunctions
    ******************Part of the error ********************
    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
    An error occurred at line: 26 in the jsp file: /includes/admin_left_nav.jsp
    Generated servlet error:
    The method convertMenus(String, String) is undefined for the type convertFunctions
    I can post any code you want.
    Note that the same application/code is working great on resin.
    Please help; I cannot explain how much I need your help
    Any help would be greatly appreciated
    Thank you in advance

    I did what asked me to do then stop/start tomcat. It did not work.
    I noticed that most of the errors are from changes I made to the classes: convertFunctions.java and UploadFile.java
    I made the changes using (JDeveloper) on my windows machine and SSH (FTP) files to the SUN server.
    Here is how I set the CLASSPATH on the sun box:
    set CLASSPATH .:/usr/jakarta-tomcat-5.5.9/common/lib/servlet-api.jar:
    /usr/jakarta-tomcat-5.5.9/common/lib/jsp-api.jar:
    /usr/jakarta-tomcat-5.5.9/common/lib/servlet.jar $CLASSPATH
    Here is my classpath after I tried to change it (No difference)
    CLASSPATH=.://export/home/oracle/oracle/product/10.2.0/db_1/jdbc/lib:/usr/jakarta-tomcat-5.5.9/common/lib:/usr/jakarta-tomcat-5.5.9/server/lib:/lib:/usr/jakarta-tomcat-5.5.9/shared/lib:/usr/jakarta-tomcat-5.5.9/server/lib/servlet.jar:../../.:/usr/jakarta-tomcat-5.5.9/server/lib/classes12.jar
    I really appreciate your help
    Thank you in advance

  • I have tomcat problem

    I have developped application using jdevelopper and try to deploy it in tomcat 5.5
    but he give me an error
    the error is :
    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
    Generated servlet error:
    Syntax error on token "import", Identifier expected after this token
         org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
         org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
         org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:397)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:288)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

    Hi,
    if I see it correctly than the problem is upon deployment and caused by Jasper reports. So either jasper.org or Apache.org is the best place to address this issue
    Frank

  • Compiling Servlet problem that uses a JavaBean

    I have a servlet that will get data from a JavaBean which is created before in a jsp file. While I trying to compile the servlet I am getting this message:
    --------------------Configuration: JDK version 1.3 <Default>--------------------
    Command : "C:\jdk1.3\bin\javac.exe" -d "C:\jakarta-tomcat-3.2.1\webapps\ROOT\WEB-INF\classes" C:\jakarta-tomcat-3.2.1\webapps\ROOT\WEB-INF\classes\MyServlet.java
    Directory : C:\jakarta-tomcat-3.2.1\webapps\ROOT\WEB-INF\classes
    C:\jakarta-tomcat-3.2.1\webapps\ROOT\WEB-INF\classes\TasitKayitGirisi.java:19: cannot resolve symbol
    symbol : class SimpleBean
    location: class MyPackage.SimpleBean
         SimpleBean simpleBean = (SimpleBean) session.getAttribute
    ^
    ("simpleBean");
    C:\jakarta-tomcat-3.2.1\webapps\ROOT\WEB-INF\classes\MyServlet.java:19: cannot resolve symbol
    symbol : class SimpleBean
    location: class MyPackage.SimpleBean
         SimpleBean simpleBean= (SimpleBean) session.getAttribute("simpleBean");
    ^
    2 errors
    Process completed.
    Where is the problem. SimpleBean is successfully being initializing in my jsp file. But I couldn't compile my servlet that will get data from that bean. Both my servlet and bean are in the same package. I am using JCreator to compile servlets. I think the problem is the compile string that JCreator uses. Can you help me. Thx in advance.

    Hi,
    The problem is it is not finding the Bean. Put it in the classpath.
    The simplest way is put the class in /WEB-INF/classes/MyPackage folder.

  • JSPC compile JSP problems (Duplicate class name)

    Hello,
    I tried to use Ant1.5.1 to compile the JSP files.
    I encountered the following problems:
    if my webapp directory structure is as
    $WEB_ROOT/index.jsp
    $WEB_ROOT/folder1/index.jsp
    I compile the JSP in Ant as following:
    <taskdef classname="org.apache.jasper.JspC" name="jasper2" >
    <classpath refid="run.classpath"/>
    </taskdef>
    <jasper2 verbose="0"
    package="eric.test.jsp"
    uriroot="${basedir}/myserv"
    webXmlFragment="${basedir}/jsp/web.xml"
    outputDir="${basedir}/jsp" />
    The Jasper(JSPC) can't append the extra folder to the index_jsp.java
    Both of the index.jsp that in the "ROOT" or in the "folder1" belongs to the same package "eric.test.jsp".
    Therefore, when I compile the .java files, it just raised the Exception "Duplicate class declaration"
    Best regards,
    Eric

    Hi Eric - did you manage to sort this problem out? I am trying to pre-compile my JSPs and I am having the same problem with duplicates classes.
    What I don't understand is that if I don't pre-compile, and I allow Tomcat to compile the JSPs when they are accessed, it appears to create duplicate classes in the same package without any problems...?

  • Netbeans 4.1 - tomcat problem

    Hello friends,
    I'm having trouble with a example program that comes with netbeans 4.1.
    It's similar to a previous post but slightly different.
    I believe it's a problem with the classpath of tomcat or catalina.
    echo %CLASSPATH%
    gives...
    .;C:\Program Files\Java\jre1.5.0_03\lib\ext\QTJava.zip
    echo %CATALINA_HOME%
    gives....
    %CATALINA_HOME%
    I'm following the HelloWeb example from the NB IDE and I get the following errors from this address:
    http://localhost:8084/auctionHouse/response.jsp
    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.JspCompilationContext.compile(JspCompilationContext.java:565)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:296)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
    root cause
    java.io.FileNotFoundException: \users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base\work\Catalina\localhost\auctionHouse\org\apache\jsp\response_jsp.java (The system cannot find the path specified)
         java.io.FileOutputStream.open(Native Method)
         java.io.FileOutputStream.<init>(FileOutputStream.java:179)
         java.io.FileOutputStream.<init>(FileOutputStream.java:70)
         org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:131)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:296)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
    note The full stack trace of the root cause is available in the Apache Tomcat/5.5.7 logs.
    Apache Tomcat/5.5.7
    I also get the following from the output screen for bundled tomcat
    Using CATALINA_BASE: \\csfiler\users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base
    Using CATALINA_HOME: C:\Program Files\NetBeans4.1\enterprise1\jakarta-tomcat-5.5.7
    Using CATALINA_TMPDIR: \\csfiler\users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base\temp
    Using JAVA_HOME: C:\Program Files\Java\jdk1.5.0_04
    Listening for transport dt_shmem at address: tomcat_shared_memory_id
    23-Feb-2006 20:43:55 org.apache.coyote.http11.Http11Protocol init
    INFO: Initializing Coyote HTTP/1.1 on http-8084
    23-Feb-2006 20:43:55 org.apache.catalina.startup.Catalina load
    INFO: Initialization processed in 1859 ms
    23-Feb-2006 20:43:55 org.apache.catalina.core.StandardService start
    INFO: Starting service Catalina
    23-Feb-2006 20:43:55 org.apache.catalina.core.StandardEngine start
    INFO: Starting Servlet Engine: Apache Tomcat/5.5.7
    23-Feb-2006 20:43:55 org.apache.catalina.core.StandardHost start
    INFO: XML validation disabled
    23-Feb-2006 20:44:04 org.apache.coyote.http11.Http11Protocol start
    INFO: Starting Coyote HTTP/1.1 on http-8084
    23-Feb-2006 20:44:04 org.apache.jk.common.ChannelSocket init
    INFO: JK2: ajp13 listening on /0.0.0.0:8009
    23-Feb-2006 20:44:04 org.apache.jk.server.JkMain start
    INFO: Jk running ID=0 time=0/110 config=null
    23-Feb-2006 20:44:04 org.apache.catalina.storeconfig.StoreLoader load
    INFO: Find registry server-registry.xml at classpath resource
    23-Feb-2006 20:44:05 org.apache.catalina.startup.Catalina start
    INFO: Server startup in 9751 ms
    Listening for transport dt_shmem at address: tomcat_shared_memory_id
    23-Feb-2006 20:54:49 org.apache.catalina.core.ApplicationContext log
    INFO: Manager: init: Associated with Deployer 'Catalina:type=Deployer,host=localhost'
    23-Feb-2006 20:54:49 org.apache.catalina.core.ApplicationContext log
    INFO: Manager: init: Global resources are available
    23-Feb-2006 20:54:49 org.apache.catalina.core.ApplicationContext log
    INFO: Manager: list: Listing contexts for virtual host 'localhost'
    23-Feb-2006 20:54:50 org.apache.catalina.core.ApplicationContext log
    INFO: Manager: list: Listing contexts for virtual host 'localhost'
    java.io.FileNotFoundException: \users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base\work\Catalina\localhost\auctionHouse\org\apache\jsp\index_jsp.java (The system cannot find the path specified)
    at java.io.FileOutputStream.open(Native Method)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:70)
    at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:131)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:296)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
    at java.lang.Thread.run(Thread.java:595)
    23-Feb-2006 20:54:52 org.apache.catalina.core.StandardWrapperValve invoke
    SEVERE: Servlet.service() for servlet jsp threw exception
    java.io.FileNotFoundException: \users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base\work\Catalina\localhost\auctionHouse\org\apache\jsp\index_jsp.java (The system cannot find the path specified)
    at java.io.FileOutputStream.open(Native Method)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:70)
    at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:131)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:296)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
    at java.lang.Thread.run(Thread.java:595)
    java.io.FileNotFoundException: \users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base\work\Catalina\localhost\auctionHouse\org\apache\jsp\response_jsp.java (The system cannot find the path specified)
    at java.io.FileOutputStream.open(Native Method)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:70)
    at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:131)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:296)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
    at java.lang.Thread.run(Thread.java:595)
    23-Feb-2006 20:57:22 org.apache.catalina.core.StandardWrapperValve invoke
    SEVERE: Servlet.service() for servlet jsp threw exception
    java.io.FileNotFoundException: \users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base\work\Catalina\localhost\auctionHouse\org\apache\jsp\response_jsp.java (The system cannot find the path specified)
    at java.io.FileOutputStream.open(Native Method)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:70)
    at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:131)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:296)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
    at java.lang.Thread.run(Thread.java:595)
    Any help would be very much appreciated.
    Stan.

    i guess your home directory (where by default netbeans creates its ".netbeans" user directory) is network mounted, and may be it has something to do with the way the directory is mounted.
    I.e . the full path to the file looks like \\csfiler\users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base\work\Catalina\localhost\auctionHouse\org\apache\jsp\response_jsp.java
    that parsed into \users\2006\sjh1\winprofile\.netbeans\4.1\jakarta-tomcat-5.5.7_base\work\Catalina\localhost\auctionHouse\org\apache\jsp\response_jsp.java
    Accessing the file using this parsed path would definitely produce FileNotFoundException until the curent drive of the accessing process is \\csfiler
    To check this, can you start netbeans with "-userdir <user_dir>", where <user_dir> to be on local filesystem, and check if you still have this problem.

  • Weird Tomcat Problem -

    I know this is not a tomcat forum, but have always been able to find help with issues @ forum.java.sun.com.
    So here's my problem on Apache Tomcat/5.5.4:
    I'm in the process of switching web-site to another host and during testing, I'm getting the following:
    org.apache.jasper.JasperException: Unable to compile class for JSP
    Generated servlet error:
    Only a type can be imported. xxx.yyy.ZxxxZxxxZxxx resolves to a packageIf I refresh page, then the jsp get's complied. If I refresh again, then maybe complied or maybe not complied.
    Code/site works fine on other host(except horrendous host up-time) and internally.
    Any suggestions would be great.
    Thanks.

    Is xxx.yyy.ZxxxZxxxZxxx a package like the error suggests? If so, try xxx.yyy.ZxxxZxxxZxxx.* if not then no clue....

  • Weird tomcat problem (class reloading)

    i have very weird problem with tomcat 3.2.3.
    for example i have html page which calls servlet.
    everything is fine when i start tomcat. now when i
    recompile servlet and try to call it again, this is
    what i get:
    Internal Servlet Error:
    java.lang.IllegalStateException: Can't happen -
    classname is null, who added this ?
         at
    org.apache.tomcat.core.ServletWrapper.loadServlet(ServletWrapper.java:261)what kind of error is this and what causes it? it
    happens even if i try to refresh html page after
    compiling.
    is there any way to fix this because it is realy
    tiring to restart tomcat each time i recompile
    servlet.
    thanx for help

    Tomcat has to be restarted after recompiling any
    servlet-class that was already invoked by tomcat.It's
    the price you have to pay for a free server.
    I think that this is not right. You can specify that an application context is "reloadable" in the server.xml file. This means that the servlet classes will be reloaded if the servlet has changed. This doesn't work for regular classes such as beans because they use a different class loader. (But Tomcat 4.0 is supposed to have something like this.) So just specify your servlets in web.xml and make sure reloadable="true" in the context in server.xml.

  • Compile / run problems with netbeans 6 but not netbeans 6 beta 1 or 5.5

    When I compile my project in netbeans IDE 6.0 (Build 200711261600) 1.6.0_01; Java HotSpot(TM) Client VM 1.6.0_01-b06 i get quite often a "can not find symbol" error or during runtime a "netbeans 6 java.lang.NoClassDefFoundError" exception. also switching between F6 or ctrl-F5 mode can cause the problem to appear.
    Compiling again or clean build resolves it.
    However running the same project under netbeans 5.5 or 6 beta 1 never gives this problem.
    any hint what might be wrong? i looked and compared the project settings but can't see any difference, but I assume that the upgrade script must have changed something.

    <?xml version="1.0" encoding="UTF-8" ?>
    - <project name="BorderDemo" default="default" basedir=".">
    <import file="nbproject/build-impl.xml" />
    </project>This is 'build.xml' file. Check for 'project.xml' file in 'nbproject' folder. You will find it to be:
    <?xml version="1.0" encoding="UTF-8" ?>
    - <project xmlns="http://www.netbeans.org/ns/project/1">
      <type>org.netbeans.modules.java.j2seproject</type>
    - <configuration>
    - <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
      <name>BorderDemo</name>
      <minimum-ant-version>1.6.5</minimum-ant-version>
    - <source-roots>
      <root id="src.dir" />
      </source-roots>
      </data>
      </configuration>
      </project>Change it to:
    <?xml version="1.0" encoding="UTF-8" ?>
    - <project xmlns="http://www.netbeans.org/ns/project/1">
      <type>org.netbeans.modules.java.j2seproject</type>
    - <configuration>
    - <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
      <name>BorderDemo</name>
      <minimum-ant-version>1.6.5</minimum-ant-version>
    - <source-roots>
      <root id="src.dir" />
      </source-roots>
      <test-roots>
      <root id="test.src.dir" />
      </test-roots>
      </data>
      </configuration>
      </project>I hope it works.....
    thanks!

  • TOMCAT problem on REDHAT 9,PLEASE HELP

    Hello, i am new to redhat and i installed tomcat 4.0.1 and it worked properly, i used tomcat for studying issues so i used to start it and stop it many times
    now when i use mozilla and try to request the server using http://localhost:8080/ ,mozilla status bar shows "Transfering data from localhost" and loops for ever
    so please help me

    I think this is not problem of redhat just check reinstalling tomcat.

  • Viewing Excel Files using Tomcat - Problem with caching

    Hi all,
    A small part of an application I'm writing has links to Excel files for users to view/download. I'm currently using Tomcat v5 as the web/app server and have some very simple code (an example is shown below) which calls the excel file.
    <%@ page contentType = "application/vnd.ms-excel" %>
    <%
    response.setHeader("Pragma", "no-cache");
    response.setHeader("Cache-Control", "no-cache");
    response.setDateHeader("Expires", 0);
    response.sendRedirect("file1.xls");
    %>
    This all works except but I'm having one big problem.
    The xls file (file1.xls) is updated via a share on the server so each month, the xls file is overwritten with the same name but with different contents. I'm finding that when an update is made to the xls file and the user then attempts to view the new file in the browser they recieve only the old xls file. It's caching the xls file and I don't want it to. How can I fix this so that it automatically gives the user the new updated file.
    The only way I've managed to get Tomcat to do this is to delete the work directory and delete the file from my IE temp folder and then restart Tomcat - this is a bit much!
    Any help would be greatly appreciated.
    Thanks.

    I'd a problem with caching a few years back, for a servlet request which returned an SVG file.
    As a workaround, I ended up putting appending "#" and a timestamp / random number after it. The browser assuming each request was new, and didn't use the cache.
    Eg.
    http://myserver/returnSVG.do#1234567
    where 1234567 is a timestamp / random.
    Not sure whether you can do this on a file based URL... but maybe worth a shot...
    regards,
    Owen

  • Tomcat problem

    Hi,
    my problem is that after installing apache-tomcat-5.5.17.exe in xp, When i write http://localhost:8080/ in internet explorer after starting tomcat then it shows following error:
    error
    requested url could not retrieved
    While trying to retrieve the URL: http://localhost:8080/
    The following error was encountered:
    Connection Failed
    The system returned:
        (111) Connection refusedThe remote host or network may be down. Please try the request again.
    Your cache administrator is root. But when i type my ip insted of locahost then its working good.
    Suppose
    http://192.168.1.6:8080 then it is working.
    what's the problem of my tomcat.
    Is there anybody can help me.
    With regards
    Bina

    First try using http://127.0.0.1:8080. (127.0.0.1 is the ip address of localhost).
    If that works then you need to update your host file to include an entry for localhost. You'll need to consult the help files, documentation or internet to determine the location of the host file for your operating system.

  • Image will not change on the Browser...Saving on the Tomcat Problem...HELP

    Hi,
    I worte a Servlet project using JBuilder 7 and TOmcat 4. THis is basically what i am doing...
    I am getting an image from database and saving it to a folder in tomcat and then displaying it on a browser.
    This application is used by multiple users...
    I am saving the Image in Tom-cat...C:\JBuilder7\jakarta-tomcat-4.0.3\webapps\examples\Image1.jpeg
    I am also displaying the image from that folder. The problem is when i run the application,
    I am seeing the same Image on the screen..Its creating the different Image file, but the image is the same.
    If i do a refresh on the page then it displays the new saved Image...
    Also, If i save the image on my local and then display it from my local it changes the images as I
    click on a Image list...
    Following is how it works when i save it and display it from my local, but if i run my application from
    another computer i am not able to see any of the images....Because its on my local.
         fos = new FileOutputStream("C:/Image1.jpeg");
         <img src="file:///C|/Image1.jpeg" height="855" name="myimage" align="middle" style="position:absolute;">;
    And this is how i am doing when i am saving to the tomcat....I am able to display it on another computer
    but would not change the image...
    fos = new FileOutputStream("../webapps/examples/Image1.jpeg");
    <img src="../Image1.jpeg" height="855" name="myimage" align="middle" style="position:absolute;">;
    Can some one please tell me what could be the Problem....
    Any help will be greatly appreciated....Thanks...

    The browser caches images so that it doesn't have to always download the same image for different pages.
    You could:
    1: Save the new image with a different name and dynamically change the name in the html.
    2: Try setting the response headers to prevent the browser from caching the images.
    response.setHeader("Pragma", "no-cache");
    response.setHeader("Cache-Control", "no-cache");
    response.setDateHeader("Expires", 0);

  • Log4j and Tomcat-problem

    Hi all,
    First I tried to add some logging to my simple Java code with a xml configuration file and it worked fine.
    Now I am trying to add logging to the whole java application in the same way which runs in tomcat and face with the foll problem.Tomcat is not able to find the configuration file.I tried to place the xml file in all feasible locations in tomcat and also tried to add in classpath but in vain.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~`
    Java Code(Which gets called in startup by another code)
    Java Code
    public class PublisherPoll implements Runnable {
    public static Logger logger = Logger.getLoggerPublisherPoll.class);//***********log4j
    public static Logger getLoggerInstance(){   //***********log4j
         return logger;
    static{
    DOMConfigurator.configure("sudarson.xml");//**********its telling it cant find/open this xml file
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error(during starting tomcat)
    log4j:ERROR Could not open [sudarson.xml].
    java.io.FileNotFoundException: sudarson.xml (The system cannot find the file sp
    cified)
    at java.io.FileInputStream.open(Native Method)
    at java.io.FileInputStream.<init>(FileInputStream.java:106)
    at java.io.FileInputStream.<init>(FileInputStream.java:66)
    at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.jav
    :583)
    at org.apache.log4j.xml.DOMConfigurator.configure(DOMConfigurator.java:
    87)
    at SerenaStartupServlet.init(SerenaStartupServlet.java:44)
    at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper
    java:1091)
    at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:9
    5)

    DOMConfigurator.configure("sudarson.xml");//**********its telling it cant find/open this xml fileWhat does "sudarson.xml" mean to you? To me, it means a file name relative to the current directory. What do you think the current directory is when you're running this in Tomcat?
    You need to research the APIs more fully, to figure out how to give it a resource name relative to the application's classpath, and put that file in said classpath.
    If I were you, I would try to avoid explicitly calling DOMConfigurator.configure altogether, and just pass the appropriate Log4J system property to the commandline that starts up Tomcat. Let Log4J worry about loading the file, given the property. If I recall correctly, the system property name is "log4j.configuration", which defaults to "log4j.properties" if unspecified. Also, rather than have each application running in Tomcat have their own log4j configuration file name, I'd name them something more universal, like "log4j.xml" - then if you deploy multiple apps in Tomcat, they can all load their own log4j.xml file, as long as (again) you corrected the "log4j.configuration" system property.

Maybe you are looking for