Tomcat – Access to Tomcat from remote PC

routesservletstomcat

I've developed a web application using servlet and tomcat. When I try to use this application from the server everything is rigth (i.e. http://localhost:8080/app_name/init.html).

However I'm having a hard time trying to access to this application from another PC. The server PC and client PC are connected using a router, there are no more computers in this network.

If, for example, the router assigns the IP 192.168.1.4 to the server PC what I write in a browser in the client PC is: http://192.168.1.4:8080/app_name/init.html

I can't run the application on the remote PC by doing this, could it an issue regarding Tomcat configuration or router configuration. I think it might be a port issue. I can provide router info if you need it.

Thanks to all

Best Answer

Sounds like your tomcat server is not configured to accept connections other than from localhost. This is a common (and sensible) default for servers.

Alternatively it may be a firewall issue on the server. If your server is running XP, there is a firewall enabled by default which will block port 8080. You can enable the port like this:

control panel -> security center -> firewall - > exceptions -> open up port 8080

Related Topic