File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Tomcat and the fly likes Tomcat Installation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Tomcat Installation" Watch "Tomcat Installation" New topic
Author

Tomcat Installation

YumeiWavrek lu
Greenhorn

Joined: Oct 02, 2004
Posts: 10
Hello,

I am trying to run Tomcat on my machine and had following problem.

Run Startup under bin directory, window Dos did fire up the second dos window and it's running but it shuts down automatically and no any error message and didn't display welcome page for me.

My Tomcat version is 5.0.16 and under XP Home Edition.

Is anybody out there had same experience?

thanks,

Yumei
YumeiWavrek lu
Greenhorn

Joined: Oct 02, 2004
Posts: 10
Here's the message I got in log file.

Can anybody make some suggestion?

thanks,

Yumei

2004-10-19 12:31:38 StandardContext[/balancer]org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule: Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.balancer.rules.RequestParameterRule: Target param name: paramName / Target param value: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balancer.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]]
2004-10-19 12:31:41 StandardContext[/jsp-examples]ContextListener: contextInitialized()
2004-10-19 12:31:41 StandardContext[/jsp-examples]SessionListener: contextInitialized()
2004-10-19 12:31:42 StandardContext[/servlets-examples]ContextListener: contextInitialized()
2004-10-19 12:31:42 StandardContext[/servlets-examples]SessionListener: contextInitialized()
2004-10-19 12:31:45 StandardContext[/servlets-examples]SessionListener: contextDestroyed()
2004-10-19 12:31:45 StandardContext[/servlets-examples]ContextListener: contextDestroyed()
2004-10-19 12:31:45 StandardContext[/jsp-examples]SessionListener: contextDestroyed()
2004-10-19 12:31:45 StandardContext[/jsp-examples]ContextListener: contextDestroyed()
YumeiWavrek lu
Greenhorn

Joined: Oct 02, 2004
Posts: 10
OK, Here's the message I got from DOS screen.

Binding Exception. can anyone help me?

thanks,


Yumei

INFO: Installing web application at context path from URL file:C:\jakarta-tomca
t-5.0.16\webapps\ROOT
Oct 19, 2004 1:10:30 PM org.apache.catalina.core.StandardHostDeployer install
INFO: Installing web application at context path /servlets-examples from URL fil
e:C:\jakarta-tomcat-5.0.16\webapps\servlets-examples
Oct 19, 2004 1:10:30 PM org.apache.catalina.core.StandardHostDeployer install
INFO: Installing web application at context path /tomcat-docs from URL file:C:\j
akarta-tomcat-5.0.16\webapps\tomcat-docs
Oct 19, 2004 1:10:30 PM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on port 8080
Oct 19, 2004 1:10:31 PM org.apache.jk.common.ChannelSocket init
INFO: JK2: ajp13 listening on /0.0.0.0:8009
Oct 19, 2004 1:10:31 PM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/80 config=C:\jakarta-tomcat-5.0.16\conf\jk2.proper
ties
Oct 19, 2004 1:10:31 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 13179 ms
StandardServer.await: create[8005]: java.net.BindException: Address already in u
se: JVM_Bind
java.net.BindException: Address already in use: JVM_Bind
at java.net.PlainSocketImpl.socketBind(Native Method)
at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:331)
at java.net.ServerSocket.bind(ServerSocket.java:318)
at java.net.ServerSocket.<init>(ServerSocket.java:185)
at org.apache.catalina.core.StandardServer.await(StandardServer.java:535
)
at org.apache.catalina.startup.Catalina.await(Catalina.java:637)
at org.apache.catalina.startup.Catalina.start(Catalina.java:599)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:297)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:398)
Oct 19, 2004 1:10:32 PM org.apache.catalina.core.StandardService stop
INFO: Stopping service Catalina
Oct 19, 2004 1:10:32 PM org.apache.coyote.http11.Http11Protocol destroy
INFO: Stoping http11 protocol on 8080 Catalina:type=ThreadPool,name=http8080
Mike Curwen
Ranch Hand

Joined: Feb 20, 2001
Posts: 3695

you have probably installed Tomcat as a service? "Address already in use" means that Tomcat is trying to bind to a port that someone else is already using. That someone else could be the instance of Tomcat that starts with your computer.

Other suspects include 'other web servers', 'other app servers', 'database servers' and 'file sharing applications'.
YumeiWavrek lu
Greenhorn

Joined: Oct 02, 2004
Posts: 10
thank you mike.

but what's that mean? I do have Eclipse and JRE on my machine but I removed them all(uninstall) and reinstall the JDK and tomcat.

the problem is persistant.

How do I check the port is being used?

Yumei
Joyce Lee
Ranch Hand

Joined: Jul 11, 2003
Posts: 1392
Hi Yumei,

Before starting tomcat, check if port 8080 is being used by running "netstat". Next, refer to "Local Address" column:

c:\> netstat -na
or
c:\> netstat -na | grep 8080


If the port is being used, track which process is listening on.

Tomcat runs on default port 8080. Check the file server.xml.

<Connector port="8080"
maxThreads="150" minSpareThreads="25" maxSpareThreads="75"


For more info on changing port, check out CoreServlet: Change Port.

Joyce
[ October 19, 2004: Message edited by: Joyce Lee ]
YumeiWavrek lu
Greenhorn

Joined: Oct 02, 2004
Posts: 10
Joyce,

Thank you very much and I got that smiling face of Tomcat in front of me now. One of the ports is used by my old version of JRE, I think.

thanks,

Yumei
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Tomcat Installation