This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
clearing_iptables [2023/05/08 04:37] – -grammar-intro hogwild | clearing_iptables [2023/05/08 04:49] (current) – added "previous" hogwild | ||
---|---|---|---|
Line 1: | Line 1: | ||
===== Clearing iptables custom commands prior to applying new ones ===== | ===== Clearing iptables custom commands prior to applying new ones ===== | ||
- | Let's say, as an example, that you wanted to use some custom iptables commands in a script, such as the firewall script. In fact, the following principles would apply to any recurring script (such as WAN Up). | + | Let's say, as an example, that you wanted to use some custom iptables commands in a script, such as the firewall script. In fact, the following principles would apply to any recurring script (such as "WAN Up"). |
\\ You can remove previously-added iptables directives using a simple approach: | \\ You can remove previously-added iptables directives using a simple approach: | ||
Line 11: | Line 11: | ||
\\ | \\ | ||
- | The commands below will check what iptables **-A** (append) or **-I** (insert) directives have been issued previously in the current Script/ | + | The commands below will check what iptables **-A** (append) or **-I** (insert) directives have been issued previously in the current Script/ |
- | \\ Here are some things | + | A user might have created custom tables in which to use advanced iptables |
- | | + | \\ Here are some rules to remember when using these commands: |
- | * A table must then be emptied with the **-F** (Flush) switch/ | + | |
+ | | ||
+ | * A table must then be emptied with the **-F** (Flush) switch/ | ||
* Only at this point will you be allowed to remove the table with the command: | * Only at this point will you be allowed to remove the table with the command: | ||
+ | |||
+ | \\ | ||