Tomcat正在运行,但8080端口未响应 [英] tomcat running ,but 8080 port not responding

查看:208
本文介绍了Tomcat正在运行,但8080端口未响应的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经通过ssh在Linux x64机器上安装了sun jdk 1.6 x64和tomcat,我没有root特权,所以我都将其安装在了自己的主目录中.

I have installed sun jdk 1.6 x64 and tomcat in a linux x64 machine through ssh, i don't have root privileges so i installed both in my home dir.

我成功运行了tomcat,但是如果我尝试输入mydomain.com:8080,则服务器无响应.

I managed to successful run tomcat but if i try to enter mydomain.com:8080 there's no answer from the server.

使用此命令:

netstat -atnp|grep LISTEN

我检查了端口,它在侦听

i checked the port and it is LISTENING

Dec 18, 2011 5:11:20 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: /home2/fiegmund/jdk1.6.0_25/jre/lib/amd64/server:/home2/fiegmund/jdk1.6.0_25/jre/lib/amd64:/home2/fiegmund/jdk1.6.0_25/jre/../lib/amd64:/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib
Dec 18, 2011 5:11:21 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Dec 18, 2011 5:11:21 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Dec 18, 2011 5:11:21 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 2015 ms
Dec 18, 2011 5:11:21 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Dec 18, 2011 5:11:21 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.23
Dec 18, 2011 5:11:21 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /home2/fiegmund/apache-tomcat-7.0.23/webapps/docs
Dec 18, 2011 5:11:24 PM org.apache.catalina.util.SessionIdGenerator createSecureRandom
INFO: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [1,869] milliseconds.
Dec 18, 2011 5:11:24 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /home2/fiegmund/apache-tomcat-7.0.23/webapps/manager
Dec 18, 2011 5:11:24 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /home2/fiegmund/apache-tomcat-7.0.23/webapps/ROOT
Dec 18, 2011 5:11:24 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /home2/fiegmund/apache-tomcat-7.0.23/webapps/examples
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jstl/core is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jstl/sql_rt is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jsp/jstl/sql is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jstl/core_rt is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jsp/jstl/core is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jsp/jstl/functions is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jstl/fmt is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/permittedTaglibs is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jstl/xml is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/scriptfree is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jstl/fmt_rt is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jsp/jstl/fmt is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jsp/jstl/xml is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jstl/xml_rt is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://java.sun.com/jstl/sql is already defined
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /home2/fiegmund/apache-tomcat-7.0.23/webapps/host-manager
Dec 18, 2011 5:11:25 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
Dec 18, 2011 5:11:25 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
Dec 18, 2011 5:11:25 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 4582 ms>

有什么问题的想法吗?

在此先感谢我写的那本糟糕的英语.

Thanks in advance and sorry for the terrible english I wrote.

推荐答案

第一步是在本地登录时运行telnet localhost 8080.然后输入类似

First step is to run telnet localhost 8080 when logged in locally. Then type in something like

GET /

,您应该重新获得HTML. 如果这不起作用,则表明tomcat不能真正正常运行或未在端口8080上侦听. 如果可以,但是从外部尝试时,请确保您具有正确的IP地址.首先尝试使用IP地址.如果IP地址有效,则可能是您的mydomain.com无法解决该问题. 如果ip是正确的(您要使用的IP地址仍然正确)并且仍然无法正常工作,则可能是您运行的防火墙不允许8080通过.更改防火墙配置需要root用户访问权限.

and you should get HTML back. If that doesn't work, then tomcat is not really running properly or is not listening on port 8080. If that works but when trying from outside, make sure that you have the correct ip address. Try with ip address first. If ip address works, perhaps your mydomain.com doesn't resolve to it. If ip is correct (the same one you are ssh'ing to) and it still doesn' work, then you are probably running firewall which doesn't allow 8080 through. Changing firewall configuration requires root access.

这篇关于Tomcat正在运行,但8080端口未响应的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆