flushing iptables

Posted by hazarus, 09-16-2007, 04:34 AM
hello, I keep trying to flush my iptables on my linux server but every time i try to do so my server seems to freeze (i lose access and have to reboot it for it to come back online), how can I go about deleting those ips manually rather than executing the flushing command? what options do I have?

Posted by FirmbIT, 09-16-2007, 06:22 AM
Check /var/log/messages to find out why your system is freezing. also: iptables -D INPUT -s 127.0.0.1 -p tcp --dport 111 -j ACCEPT replace the IP and port with the correct information.

Posted by david510, 09-16-2007, 06:59 AM
You can see the iptables rules inside the file /etc/sysconfig/iptables and delete the entries manually from there.

Posted by case42, 09-16-2007, 09:37 AM
I doubt the system really "freezes" - I suspect what you're doing is flushing all rules permitting you access while the iptables default policy is DROP or REJECT, thus rendering your box inaccessible. Make sure that before flushing the rules, you set the INPUT and OUTPUT policies to ACCEPT, like this: The current policies can be listed with: Check the very first line in the output.

Posted by zacharooni, 09-16-2007, 10:48 AM
Yeah, that's happened to me SO many times.. It's because you're dropping all your traffic coming into and out of the box with a default policy of DROP, meaning no traffic is permitted to go through any way. All you really need to do is iptables -P INPUT ACCEPT && iptables -F

آیا این پاسخ به شما کمک کرد؟

 پرینت این مقاله

در همین زمینه

MySQL SELECT using WHERE and OR

Posted by HostRefugee-Vince, 03-23-2007, 08:47 PMHi, The following SELECT statement is giving...

Remount back up hard drive

Posted by Peter_Net, 09-15-2007, 07:41 PMHello, I have a second hard disk for cpanel back up...

Email issue

Posted by manindarkjp, 03-30-2008, 08:31 AMHello, I have a dedicate server and got a problem...

M2M Host Offers Discount Across All Web Hosting Plan This Christmas!

Posted by livechatdir, 12-17-2009, 08:49 PM M2M Host, the leading web hosting company...

Eaccellerator?

Posted by dragon2611, 01-12-2008, 09:13 PMI believe I understand what it does (cache php scripts...