Need help with Iptable/Firewall on RHEL.

Hi Gurus,

I am facing an issue with firewalls on one of my Linux Box.

Issue : Port 8001 looks open to me and there is a weblogic process running on it

netstat -alnp | grep 8001
tcp        0      0 ::ffff:3.20.247.165:8001    :::*                        LISTEN      28768/java
lsof -ni tcp:8001
COMMAND   PID   USER   FD   TYPE    DEVICE SIZE NODE NAME
java    28768 xxxxxxx  362u  IPv6 348588617       TCP 3.20.247.165:vcom-tunnel (LISTEN)

but when I try to connect to that port externally I am not able to I tested using telnet to check that but failed. it said could not connect. Can you suggest how to check if this port is blocked outside the OS .

Thanks In Advance.
Rama Krishna.

First, check to see if you can connect to that port when logged into the same server.

For example. telnet localhost 8001

1 Like

Neo Thanks for the response. I tried to telnet but no luck.

Do you have an entry in /etc/sysconfig/iptables like this? If not, do add that before the FORWARD chain begins and restart the iptables service:

-A INPUT -m state --state NEW -m tcp -p tcp --dport 8001 -j ACCEPT

To check if a port is open or not on a remote machine, you have a very versatile tool called "nmap". RedHat repository has this tool and you can install it with yum.

1 Like

Thanks Guys for the responses. I found the issue under the iptables files the order of entry was not correct . I fixed it and its working

Cheers!! :b: :smiley: