localhost:8080/lio/
在我的apache tomcat中效果很好,但是当我使用<my ip>106.5x.xx.xx:8080/lio/
时出现此错误:
The connection has timed out
The server at 106.5x.xx.xx is taking too long to respond.
The site could be temporarily unavailable or too busy. Try again in a few moments.
If you are unable to load any pages, check your computer's network connection.
If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the Web.
答案 0 :(得分:1)
在评论中,您说您使用whatsmyip.com进行IP地址。这是您的路由器公共IP地址,而不是您的PC。要从您的PC获取IP,请执行以下操作
Windows上的:
ipconfig
Linux上的(需要root权限):
ifconfig
当然,您只能通过这种方式从本地网络访问您的tomcat。如果您希望能够从互联网访问您的PC,则必须在路由器上设置端口转发(如果支持)。