H do I stop Iptables firewall under Debian Linux server system?
The iptables command is used to set up, maintain, and inspect the tables of IPv4 packet filter rules in the Linux kernel.
Several different tables may be defined. Each table contains a number of built-in chains and may also contain user-defined chains. You can use the following commands to stop firewall under Debian Linux.
First you need to login as root user.
If it is a remote server login over the ssh session using the following syntax:
$ ssh firstname.lastname@example.org
The syntax is as follows:
iptables -t table -X
iptables -t table -F
iptables -P chain ACCEPT
To flush the selected chain or all the chains in the table pass the -F option to iptables command. This is equivalent to deleting all the rules one by one. To delete the optional or all the user-defined chain pass the -X option to iptables command. You also need to delete nat and mangle tables using the -F and -X options. Finally, set the default policy to ACCEPT.
Type the following command to save existing iptables configuration.
iptables-save > /root/working.iptables.rules
To stop firewall type the following commands (see syntax above for detiled information):
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 OUTPUT ACCEPT iptables -P FORWARD ACCEPT
You can also use this shell script to stop firewall.TwitterFacebookGoogle+PDF versionFound an error/typo on this page? Help us!
- 30 Cool Open Source Software I Discovered in 2013
- 30 Handy Bash Shell Aliases For Linux / Unix / Mac OS X
- Top 30 Nmap Command Examples For Sys/Network Admins
- 25 PHP Security Best Practices For Sys Admins
- 20 Linux System Monitoring Tools Every SysAdmin Should Know
- 20 Linux Server Hardening Security Tips
- Linux: 20 Iptables Examples For New SysAdmins
- Top 20 OpenSSH Server Best Security Practices
- Top 20 Nginx WebServer Best Security Practices
- 20 Examples: Make Sure Unix / Linux Configuration Files Are Free From Syntax Errors
- 15 Greatest Open Source Terminal Applications Of 2012
- My 10 UNIX Command Line Mistakes
- Top 10 Open Source Web-Based Project Management Software
- Top 5 Email Client For Linux, Mac OS X, and Windows Users
- The Novice Guide To Buying A Linux Laptop