You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Konstantin L Kouptsov <kl...@panix.com> on 2006/03/19 22:31:50 UTC

tomcat examples

Hello,

I am trying to learn using tomcat and writing servlets. After I 
installed Tomcat 5.5.16 for windows and pointed my browser to 
localhost:8080, I can see the tomcat page. However, when I try to access 
"JSP examples" or "servlet examples" in the left panel menu, I get a 404 
page (The requested resource is not available). Similarly, when I choose 
"Tomcat manager" link on the left, the jsp-examples and 
servlets-examples applications are shown not running and cannot be 
started. Can someone advise?

Also, is there a way to have a non-default location of the pages to be 
served (i.e. other than $CATALINA_HOME/webapps/ROOT/)?

KK.



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


RE: tomcat examples

Posted by erha <r_...@yahoo.com>.
Hi Chuck, 
>> And below is the error from the log file for my case. Anybody 
>> body know what is wrong ? 
>> 
>> java.lang.ClassFormatError: Extra bytes at the end of class file 
>> listeners/ContextListener 

>As I stated before: that class file is bad.  It appears to be one you 
>created, not from the Tomcat installation.  You need to recompile it or 
>otherwise correct it. 

Sorry I am quite new with Tomcat/Java. 
But here is what I have done: 
Download the apache-tomcat-5.5.16.exe, install and run the service. 
Got this error immediately. 
Havent got chance to create any class yet. 

> - Chuck 

Rudy 

--
View this message in context: http://www.nabble.com/tomcat-examples-t1307951.html#a3493587
Sent from the Tomcat - User forum at Nabble.com.


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


RE: tomcat examples

Posted by erha <r_...@yahoo.com>.
Thanks Chucks.

Will try to download the zip then.

Rudy
--
View this message in context: http://www.nabble.com/tomcat-examples-t1307951.html#a3505817
Sent from the Tomcat - User forum at Nabble.com.


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


Re: tomcat examples

Posted by Konstantin L Kouptsov <kl...@panix.com>.
> Hi Chuck,
>>> And below is the error from the log file for my case. Anybody
>>> body know what is wrong ?
>>>
>>> java.lang.ClassFormatError: Extra bytes at the end of class file
>>> listeners/ContextListener
>
>> As I stated before: that class file is bad.  It appears to be one you
>> created, not from the Tomcat installation.  You need to recompile it or
>> otherwise correct it.
>
> Sorry I am quite new with Tomcat/Java.
> But here is what I have done:
> Download the apache-tomcat-5.5.16.exe, install and run the service.
> Got this error immediately.
> Havent got chance to create any class yet.


I did the same. Fresh install of Win XP, Tomcat-5.5.16 and everything 
else.

I had put some external example to webapps, and both jsp and servlets in 
it work fine. So, the problem is only with examples that come with 
Tomcat-5.5.16.

Konstantin.

>
>> - Chuck
>
> Rudy
>
>
> --
> View this message in context: http://www.nabble.com/tomcat-examples-t1307951.html#a3493565
> Sent from the Tomcat - User forum at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

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


Re: tomcat examples

Posted by erha <r_...@yahoo.com>.
Hi Chuck,
>> And below is the error from the log file for my case. Anybody 
>> body know what is wrong ?
>> 
>> java.lang.ClassFormatError: Extra bytes at the end of class file
>> listeners/ContextListener

>As I stated before: that class file is bad.  It appears to be one you
>created, not from the Tomcat installation.  You need to recompile it or
>otherwise correct it.

Sorry I am quite new with Tomcat/Java.
But here is what I have done:
Download the apache-tomcat-5.5.16.exe, install and run the service.
Got this error immediately.
Havent got chance to create any class yet.

> - Chuck

Rudy


--
View this message in context: http://www.nabble.com/tomcat-examples-t1307951.html#a3493565
Sent from the Tomcat - User forum at Nabble.com.


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


Re: tomcat examples

Posted by erha <r_...@yahoo.com>.
I have the same problem here.

And below is the error from the log file for my case. Anybody body know what
is wrong ?

Mar 20, 2006 12:29:31 AM org.apache.catalina.core.StandardContext
listenerStart
SEVERE: Error configuring application listener of class
listeners.ContextListener
java.lang.ClassFormatError: Extra bytes at the end of class file
listeners/ContextListener
	at java.lang.ClassLoader.defineClass1(Native Method)
	at java.lang.ClassLoader.defineClass(Unknown Source)
	at java.security.SecureClassLoader.defineClass(Unknown Source)
	at
org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1812)
	at
org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:866)
	at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1319)
	at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1198)
	at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3677)
	at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4183)
	at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
	at
org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:904)
	at
org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:867)
	at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:474)
	at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1112)
	at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
	at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
	at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
	at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
	at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
	at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
	at org.apache.catalina.core.StandardService.start(StandardService.java:450)
	at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
	at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:275)
	at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
--
View this message in context: http://www.nabble.com/tomcat-examples-t1307951.html#a3487646
Sent from the Tomcat - User forum at Nabble.com.


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