You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by pcampaigne <pc...@charter.net> on 2003/03/11 15:59:41 UTC

HTTP 500-Internal Server Error

Hi,
I'm trying to setup database access with a simple test application using tomcat 4.0.6.
When my servlet gets executed I get the 500 browser error,
"Wrapper cannot find servlet class com.op.test.LoginServlet or a class it depends on"
1. Does anyone know why?
2. Is there any way to get more useful error messages?
Thanks,
Phil Campaigne    

I have the following entry in my web.xml file to address this:

"<serlvet>
    <servlet-name>LoginServlet</servlet-name>
<display-name>LoginServlet</display-name>
<servlet-class>com.op.test.LoginServlet</servlet-class>
<init-param-name>debug</param-name>
<param-value>2</param-value>
<init-param>
</servlet>

<servlet-mapping>
<servlet-name>LoginServlet</servlet-name>
<url-pattern>LoginServlet</url-pattern>
</servlet-mapping>

Re: HTTP 500-Internal Server Error

Posted by pcampaigne <pc...@charter.net>.
Eric,
Thanks for your help!
Phil
----- Original Message -----
From: "Erik Price" <ep...@ptc.com>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Tuesday, March 11, 2003 10:20 AM
Subject: Re: HTTP 500-Internal Server Error


>
>
> pcampaigne wrote:
> > Thanks Matt.
> > I had my servlets in the "src" directory under WEB-INF so I creates a
> > classes directory under WEB-INF and moved them there.
> >
> > However, I still get a 500 error but the root cause is different:
> > "NoClassDefinitionFoundError: com/op/test/LoginServlet  (wrong name:
> > LoginServlet)
> >
> > It seems to me that the web.xml entry should  resolve this.  I still
don't
> > get it.
>
> Your directory hierarchy should look something like this, where each
> item followed by a slash is a directory:
>
> -<webappname>/
>    -any JSP or HTML files you are using are probably here
>    -WEB-INF/
>      -lib/
>        -any JAR files you are using go here
>      -classes/
>        -com/
>           -op/
>            -test/
>              - LoginServlet
>
>
>
> Erik
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: HTTP 500-Internal Server Error

Posted by Erik Price <ep...@ptc.com>.

pcampaigne wrote:
> Thanks Matt.
> I had my servlets in the "src" directory under WEB-INF so I creates a
> classes directory under WEB-INF and moved them there.
> 
> However, I still get a 500 error but the root cause is different:
> "NoClassDefinitionFoundError: com/op/test/LoginServlet  (wrong name:
> LoginServlet)
> 
> It seems to me that the web.xml entry should  resolve this.  I still don't
> get it.

Your directory hierarchy should look something like this, where each 
item followed by a slash is a directory:

-<webappname>/
   -any JSP or HTML files you are using are probably here
   -WEB-INF/
     -lib/
       -any JAR files you are using go here
     -classes/
       -com/
          -op/
           -test/
             - LoginServlet



Erik


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: HTTP 500-Internal Server Error

Posted by pcampaigne <pc...@charter.net>.
Thanks Matt.
I had my servlets in the "src" directory under WEB-INF so I creates a
classes directory under WEB-INF and moved them there.

However, I still get a 500 error but the root cause is different:
"NoClassDefinitionFoundError: com/op/test/LoginServlet  (wrong name:
LoginServlet)

It seems to me that the web.xml entry should  resolve this.  I still don't
get it.
Phil
----- Original Message -----
From: "Matthew Oatham" <ma...@hotmail.com>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Tuesday, March 11, 2003 8:37 AM
Subject: Re: HTTP 500-Internal Server Error


> Is LoginServlet.class in WEB-INF/classes ?
>
> Does LoginServlet.class import any helper classes from third party
> aplications? If so are these JAR files in WEB-INF/lib ?
>
> If you are using the specified context is your application under the dir
> webapps/Test ?
>
> Are you accessing the servlet on http://domain:port/Test/LoginServlet ?
>
> Not sure if any of this will help but younever know!!!
>
> Matt.
>
>
> ----- Original Message -----
> From: "pcampaigne" <pc...@charter.net>
> To: "Tomcat Users List" <to...@jakarta.apache.org>
> Sent: Tuesday, March 11, 2003 4:13 PM
> Subject: Re: HTTP 500-Internal Server Error
>
>
> > Hi,
> > I found some more information about my problem, the root cause is
> > ClassNotFoundException: com.op.test.LoginServlet
> > but I have the web.xml entry shown below, and also the following context
> > entry in server.xml
> >
> > <!-- Test Context -->
> > <Context path="/Test" docBase=Test"
> > debug="100" privileged="true"/>
> >
> > I don't get it??
> > Phil
> > ----- Original Message -----
> > From: "pcampaigne" <pc...@charter.net>
> > To: "Tomcat Users List" <to...@jakarta.apache.org>
> > Sent: Tuesday, March 11, 2003 6:59 AM
> > Subject: HTTP 500-Internal Server Error
> >
> >
> > Hi,
> > I'm trying to setup database access with a simple test application using
> > tomcat 4.0.6.
> > When my servlet gets executed I get the 500 browser error,
> > "Wrapper cannot find servlet class com.op.test.LoginServlet or a class
it
> > depends on"
> > 1. Does anyone know why?
> > 2. Is there any way to get more useful error messages?
> > Thanks,
> > Phil Campaigne
> >
> > I have the following entry in my web.xml file to address this:
> >
> > "<serlvet>
> >     <servlet-name>LoginServlet</servlet-name>
> > <display-name>LoginServlet</display-name>
> > <servlet-class>com.op.test.LoginServlet</servlet-class>
> > <init-param-name>debug</param-name>
> > <param-value>2</param-value>
> > <init-param>
> > </servlet>
> >
> > <servlet-mapping>
> > <servlet-name>LoginServlet</servlet-name>
> > <url-pattern>LoginServlet</url-pattern>
> > </servlet-mapping>
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: HTTP 500-Internal Server Error

Posted by Matthew Oatham <ma...@hotmail.com>.
Is LoginServlet.class in WEB-INF/classes ?

Does LoginServlet.class import any helper classes from third party
aplications? If so are these JAR files in WEB-INF/lib ?

If you are using the specified context is your application under the dir
webapps/Test ?

Are you accessing the servlet on http://domain:port/Test/LoginServlet ?

Not sure if any of this will help but younever know!!!

Matt.


----- Original Message -----
From: "pcampaigne" <pc...@charter.net>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Tuesday, March 11, 2003 4:13 PM
Subject: Re: HTTP 500-Internal Server Error


> Hi,
> I found some more information about my problem, the root cause is
> ClassNotFoundException: com.op.test.LoginServlet
> but I have the web.xml entry shown below, and also the following context
> entry in server.xml
>
> <!-- Test Context -->
> <Context path="/Test" docBase=Test"
> debug="100" privileged="true"/>
>
> I don't get it??
> Phil
> ----- Original Message -----
> From: "pcampaigne" <pc...@charter.net>
> To: "Tomcat Users List" <to...@jakarta.apache.org>
> Sent: Tuesday, March 11, 2003 6:59 AM
> Subject: HTTP 500-Internal Server Error
>
>
> Hi,
> I'm trying to setup database access with a simple test application using
> tomcat 4.0.6.
> When my servlet gets executed I get the 500 browser error,
> "Wrapper cannot find servlet class com.op.test.LoginServlet or a class it
> depends on"
> 1. Does anyone know why?
> 2. Is there any way to get more useful error messages?
> Thanks,
> Phil Campaigne
>
> I have the following entry in my web.xml file to address this:
>
> "<serlvet>
>     <servlet-name>LoginServlet</servlet-name>
> <display-name>LoginServlet</display-name>
> <servlet-class>com.op.test.LoginServlet</servlet-class>
> <init-param-name>debug</param-name>
> <param-value>2</param-value>
> <init-param>
> </servlet>
>
> <servlet-mapping>
> <servlet-name>LoginServlet</servlet-name>
> <url-pattern>LoginServlet</url-pattern>
> </servlet-mapping>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: HTTP 500-Internal Server Error

Posted by pcampaigne <pc...@charter.net>.
Hi,
I found some more information about my problem, the root cause is
ClassNotFoundException: com.op.test.LoginServlet
but I have the web.xml entry shown below, and also the following context
entry in server.xml

<!-- Test Context -->
<Context path="/Test" docBase=Test"
debug="100" privileged="true"/>

I don't get it??
Phil
----- Original Message -----
From: "pcampaigne" <pc...@charter.net>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Tuesday, March 11, 2003 6:59 AM
Subject: HTTP 500-Internal Server Error


Hi,
I'm trying to setup database access with a simple test application using
tomcat 4.0.6.
When my servlet gets executed I get the 500 browser error,
"Wrapper cannot find servlet class com.op.test.LoginServlet or a class it
depends on"
1. Does anyone know why?
2. Is there any way to get more useful error messages?
Thanks,
Phil Campaigne

I have the following entry in my web.xml file to address this:

"<serlvet>
    <servlet-name>LoginServlet</servlet-name>
<display-name>LoginServlet</display-name>
<servlet-class>com.op.test.LoginServlet</servlet-class>
<init-param-name>debug</param-name>
<param-value>2</param-value>
<init-param>
</servlet>

<servlet-mapping>
<servlet-name>LoginServlet</servlet-name>
<url-pattern>LoginServlet</url-pattern>
</servlet-mapping>



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org