Need a little help here.
My server went offline yesterday. After doing portscan it turned out that all the ports are filtered :
Starting Nmap 5.00 Click at 2012-06-01 14:28 UTC
All 1000 scanned ports on (xxx.xxx.xxx.xxx) are filtered
Nmap done: 1 IP address (1 host up) scanned in 201.06 seconds
So I figured out it's the firewall. Now I can only start server in recovery mode to access data.
How do I flush Iptables in this case?
I have tried to put "iptables -F" in rc.local and then rebooting, but that didn't work out so far.
any ideas?
Answered By
amfoi
0 points
N/A
#142146
Firewall Problem on Debian 5.0 Linux
It is not a firewall problem, It's a bug in Debian 5.
That's why you are encountering a problem.
It doesn't work correctly with your NIC in your hardware.
I suggest you should upgrade to squeeze
Firewall Problem on Debian 5.0 Linux
Good day!
I assumed you were frustrated about this because your server went offline, and it is not your firewall that have caused this. in order to resolve this follow these simple steps to flush all iptables :
Â
A. Open and used a text editor like VI then Create /root/fw.stop /etc/init.d/fw.stop script
"#!/bin/sh
echo "Stopping firewall and allowing everyone…"
iptables -F
iptables -X
iptables -t nat -F
iptables -t nat -X
iptables -t mangle -F
iptables -t mangle -X
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT"
Â
B. Examine if you can really execute the script.
Â
# chmod +x /root/fw.stop
Â
C. Run the script :Â
# chmod +x /root/fw.stop
Â
Hope I have helped you!
Â
Take care!