#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2002
    Location
    Christchurch, New Zealand
    Posts
    0
    Rep Power
    0

    Question 404 Error With Apache Tomcat/4.0.3


    We've just installed Tomcat on our server, but it doesn't seem to want to display .jsp pages. It always gives 404 Errors.

    http://66.246.14.187/test.jsp

    The file is definitely there. What would be causing this?
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2002
    Location
    Boston, MA
    Posts
    30
    Rep Power
    56
    Two ways to troubleshoot:
    1) Start with basic test case and see if it works.
    2) Simplify the current situation and clean it up.

    Take the first and second approach:

    1) a. Try a totally simple hello WWW webapp in tomcat. Register a context element in server.xml

    b. Once you get that to work, copy some files from your real webapp and restart Tomcat.


    2) a. take a look at your current web-app.

    b. Look at the doctype in your web.xml file.
    Is it missing the xml declaration and/or doctype? Are all of the elements in the correct order? Do the servlet-mappings and url-patterns exist? A bad web.xml file will cause problems. Usually this problem prevents Tomcat from even starting, but I am using 4.0.2, not 4.0.3, maybe there is a difference. you can save your web.xml file as _web.xml and make a new web.xml to test. Just use an xml declaration, a doctype, and a webapp element.

    Comments on this post

    • Yawmark agrees

IMN logo majestic logo threadwatch logo seochat tools logo