Problem description :
CentOS 6.5 Installation Complete Tomcat after accessing the Local: http://localhost:8080/is correct, but the LAN is inaccessible。
reason :
/etc/init.d/iptables status
Table:filter
Chain INPUT (Policy ACCEPT)
Num Target prot opt source destination
1 Rh-firewall-1-input All--0.0.0.0/0 0.0.0.0/0
Chain FORWARD (Policy ACCEPT)
Num Target prot opt source destination
1 Rh-firewall-1-input All--0.0.0.0/0 0.0.0.0/0
Chain OUTPUT (Policy ACCEPT)
Num Target prot opt source destination
Chain Rh-firewall-1-input (2 references)
Num Target prot opt source destination
1 ACCEPT All--0.0.0.0/0 0.0.0.0/0
2 ACCEPT ICMP--0.0.0.0/0 0.0.0.0/0 ICMP type 255
3 ACCEPT ESP--0.0.0.0/0 0.0.0.0/0
4 ACCEPT AH--0.0.0.0/0 0.0.0.0/0
5 ACCEPT UDP--0.0.0.0/0 224.0.0.251 UDP dpt:5353
6 ACCEPT UDP--0.0.0.0/0 0.0.0.0/0 UDP dpt:631
7 ACCEPT TCP--0.0.0.0/0 0.0.0.0/0 TCP dpt:631
8 ACCEPT All – 0.0.0.0/0 0.0.0.0/0 State related,established
9 ACCEPT TCP--0.0.0.0/0 0.0.0.0/0 state NEW TCP dpt:22
Ten REJECT All--0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited
will get a series of messages stating that the firewall is open.
Workaround 1:
/etc/init.d/iptables stop
Flushing firewall rules: [OK]
Setting chains to Policy Accept:filter [OK]
Unloading iptables modules: [OK]
permanently closed:
chkconfig--level iptables off
Workaround 2:
1. Modify the file/etc/sysconfig/iptables
# cd/etc/sysconfig/
# VI Iptables
Add a line:
-A rh-firewall-1-input-m State--state new-m tcp-p TCP--dport 8080-j ACCEPT
Iptables Service Restart:
# Service Iptables Restart
Play Linux-CentOS 6.5,tomcat cannot be accessed remotely