Can't connect to website after altering IPTables
Posted
by
user2833135
on Server Fault
See other posts from Server Fault
or by user2833135
Published on 2013-10-31T02:46:21Z
Indexed on
2013/10/31
3:56 UTC
Read the original article
Hit count: 751
I attempted to open up a port on my VPS, but I can't connect to my website after opening up that port. Below are the commands I issued to open the port. I didn't get an error or anything after setting this up. I just can't connect to my website after doing this.
[root@vps ~]# iptables -F
[root@vps ~]# iptables -A INPUT -i lo -j ACCEPT
[root@vps ~]# iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
[root@vps ~]# iptables -A INPUT -p tcp --dport 25765 -j ACCEPT
[root@vps ~]# iptables -P INPUT DROP
[root@vps ~]# iptables -P FORWARD DROP
[root@vps ~]# iptables -P OUTPUT ACCEPT
[root@vps ~]# iptables -L -v
Just a side note, but I am running CentOS 6 (64 bit)
Thank you in advance.
© Server Fault or respective owner