Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Tomcat not running on windows 7

 
Boris Zarate
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I have a windows 7 (professional edition) machine, where I installed apache-tomcat-6.0.33, together with jre-7-windows-x64. The installation runs without problem, I am able to find the apache icon at the inferior right corner, but when I go to http://localhost:8080 I get the bad request error.

I have tried giving administrator privileges to both: Tomcat6w and Tomcat6 files in the tomcat6 bin folder (right click, compatibility). I have tried to start the tomcat from the command prompt using "net start tomcat6" and it says that it was started successfully, but I get the bad request error in http://localhost:8080. I double checked the port through the server.xml file where i find the line "Connector port="8080" redirectPort="8443" connectionTimeout="20000" protocol="HTTP/1.1"/".

If I start and then stop the service (manually from command prompt) I get this log file:


2011-10-12 15:05:03 Commons Daemon procrun stderr initialized
Oct 12, 2011 3:05:03 PM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Apache Software Foundation\Tomcat 6.0\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\MATLAB\R2011a\bin;;.
Oct 12, 2011 3:05:03 PM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
Oct 12, 2011 3:05:03 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 452 ms
Oct 12, 2011 3:05:03 PM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Oct 12, 2011 3:05:03 PM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.33
Oct 12, 2011 3:05:03 PM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor manager.xml
Oct 12, 2011 3:05:04 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory docs
Oct 12, 2011 3:05:04 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory ROOT
Oct 12, 2011 3:05:04 PM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
Oct 12, 2011 3:05:04 PM org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8009
Oct 12, 2011 3:05:04 PM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/16 config=null
Oct 12, 2011 3:05:04 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 335 ms
Oct 12, 2011 3:05:37 PM org.apache.coyote.http11.Http11Protocol pause
INFO: Pausing Coyote HTTP/1.1 on http-8080
Oct 12, 2011 3:05:38 PM org.apache.catalina.core.StandardService stop
INFO: Stopping service Catalina
Oct 12, 2011 3:05:38 PM org.apache.coyote.http11.Http11Protocol destroy
INFO: Stopping Coyote HTTP/1.1 on http-8080


But I do not see any error in there.

I should mention that I tried installing apache-tomcat-7.0.22 and I got the same thing, I tried installing jdk-7-windows-x64 and I got the same thing. I granted access to the file Tomcat6w in firewall and I got same thing. I added the variable and the path %JAVA_HOME% to the environment variables, but nothing. Additionally, I should mention that I am trying to access the http://localhost:8080 from both IE and Chrome. In IE I get the bad request error, but in Chrome I get a blank page that only says "fail".

I am running out of ideas. Does any one have a suggestion ?

Thanks,

Boris
 
Yogaraj Khanal
Ranch Hand
Posts: 54
Eclipse IDE Mac OS X Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you download JDK6 instead and point your JAVA_HOME to this and test so that you can isolate whether its tomcat or JDK issue.
I do have some problems using JDK7 sometimes.
 
Boris Zarate
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you for your reply. I actually did that and in my case it was not enough to solve the issue. I actually solved the issue by running the command "netstatistics -a" and I found that another application was using the 8080 port. No idea which application, since it was a new machine with the OS only. I changed the port in the tomcat7 and it worked. Now I have my service working. Again, thank you for your suggestion.
 
manu manige
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi....i downloaded apache tomcat and installed it and i started startup.bat then the command prompt displays very fastly and disappears....... i have already set the JAVA_HOME AND java path....whats the problem behind it? and how can i fix that? please reply me with a solution to fix this........thanks in advance...........
 
Boris Zarate
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Manu,

Have you tried running tomcat from the DOS terminal ("tomcat start") ?. What error does it show ?. If it does not show any error try going in the web browser to "http:\\localhost:8080". Let us know any errors you got.
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13058
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
To avoid that window opens and immediately closes - carrying all the error information with it - do this:

In startup.bat - the last executable line - use run instead of start



this will execute catalina.bat in the open window and you can see whats happening. When start is used, you get that new window.

Execute startup.bat from a command prompt window.

Bill
 
barkha chotrani
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
when m clicking on startup.bat file ..i get command prompt but disappears within a fraction of second ...could someone please answer to this??
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13058
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just re-read my previous message please.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic