2

I installed Tomcat 6.0 into Fedora 10. I'm able to see my webapp on browser doing a simple http://localhost:8080/HomeApp from the server computer. I saw that my server computer has an IP of 192.168.1.5 by doing /sbin/ifconfig. So I replaced the localhost with the server IP and it was also working.

However when I go to another computer at home I get "Connection timed out". This is weird because I can actually ping the home server from the client computer successfully.

Anyone knows whats wrong? I'm using this Verizon Fios as my home router with default configurations. Thanks in advance.

Marquinio
  • 4,601
  • 13
  • 45
  • 68
  • Server and "another computer" are both at home? – thejh Nov 20 '10 at 00:02
  • Are you sure your port 8080 isn't blocked by firewall? – buru Nov 20 '10 at 00:28
  • ok probably something wrong with port 8080. I just deployed the same web application to a Windows computer running Tomcat under port 80 and it worked. I will switch the Unix Tomcat to run on port 80 and try again... I – Marquinio Nov 20 '10 at 00:33
  • 4
    run `/sbin/service iptables stop` and `/sbin/service ip6tables stop` to stop the firewall on fedora, it's probably on and blocking port 8080 – nos Nov 20 '10 at 00:52
  • ok I'm new to Linux but doing a tcpdump I saw something "ICMP host new-host.home unreachable - admin prohibited.....". @nos I will try your suggestion, I think it has to do with the Fedora firewall like you mentioned. – Marquinio Nov 20 '10 at 00:58

1 Answers1

0

Any application (tomcat in this case) can bind to any address or to a specific address. I guess your tomcat installation is binded to localhost only, that's why you can't access it from another host.

Look for the tomcat/conf/server.xml file and look for some text like:

<Connector 
    port="8080" 
    protocol="HTTP/1.1" 
    address="127.0.0.1"
    ...

If you find the address attribute, remove it and it should bind to every ip addres (i.e. localhost and 192.168.1.5).

pmoleri
  • 4,238
  • 1
  • 15
  • 25
  • 2
    Thanks. Actually dropping the default Fedora10 firewall worked for me. Credit goes to NOS who provided me with the answer. Look at comments above, expand comments to see it. But what you mention is interesting, didn't know that and I'll keep that in mind. – Marquinio Nov 23 '10 at 14:33