开发者

Why http://localhost:8080 available while 127.0.0.1 not? (JSP on MyEclipse+Tomcat)

开发者 https://www.devze.com 2022-12-14 23:46 出处:网络
The System\'s hosts file is fine, 127.0.0.1localhost is there... Ping 127.0.0.1,or my IP, the result is also fine..

The System's hosts file is fine, 127.0.0.1 localhost is there...

Ping 127.0.0.1,or my IP, the result is also fine..

Myeclipse's version is 8.0 and I'm just using the Tomcat within it.

A simple JSP+Javabean web project so is deployed.

Now the situation is when I open MyEclipse and start the Tomcat, I can access my site throuth http://localhost:8080/so/index.jsp, and it displays and runs well (this means 8080 port is all right,right?).But http://127.0.0.1:8080/so/index.jsp is a blank page(no source code) in K-Meleon and the page can't be found开发者_如何学Go in IE.

Still when I tried to access it from another pc in LAN, 'http://myIP:8080/so/index.jsp', it worked only a little. The browser can load the homepage but without CSS, and clicking on any link or even refreshing the page leads to an error page..(While the site gose quite well on my own pc accessed throught localhost)

Is there anyone have ever met this situation?


If you configured tomcat to only listen on the non-loopback interface, this is what you'd get.

See this description of how this gets configured in server.xml.

Use the netstat -a to see what your tomcat is actually listening on.

0

精彩评论

暂无评论...
验证码 换一张
取 消