Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 09-18-2008, 04:34 AM   #1
LQ Newbie
Registered: Sep 2008
Posts: 10

Rep: Reputation: 0
Unhappy Which is the chain name in iptables

Hi all,

i hav queued a lot rules in my iptable.
and i want to replace one.
i have found that i can do so with
iptables -E
but sytax is -E old-chain-name new-chain-name

what is the chain name in iptables?

plz help i dont wish to flush all the things.

any help will be appreciated.
Old 09-19-2008, 04:34 AM   #2
Senior Member
Registered: Sep 2002
Location: Philippines
Distribution: Slackware, RHEL&variants, AIX, SuSE
Posts: 1,127

Rep: Reputation: 49
chain name, is the one that comes after the word "Chain"
when you run "iptables -L", like:

Chain FORWARD (policy ACCEPT)
Old 09-20-2008, 09:03 AM   #3
Senior Member
Registered: Oct 2003
Location: Bonaire
Distribution: Debian Wheezy/Jessie/Sid, Linux Mint DE
Posts: 4,501

Rep: Reputation: 636Reputation: 636Reputation: 636Reputation: 636Reputation: 636Reputation: 636
The best way to maintain iptables is to build a bash script which enters iptables rules one by one.
It is much easier to do than printing out the current rule set and making changes, especially if the number of rules get larger than 30 or so.
With the script you start by flushing everything, and you are sure you enter into iptables exactly what is in your script.

Old 09-21-2008, 08:39 PM   #4
LQ Guru
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 8,208
Blog Entries: 4

Rep: Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764
(Shrug...) For better or worse, I use Shorewall.

Anyhow: a "chain name" is basically just a moniker. It's a way to name and group rules.
Old 09-22-2008, 05:23 AM   #5
LQ Newbie
Registered: Sep 2008
Posts: 10

Original Poster
Rep: Reputation: 0
tahnx all...
i got it


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
iptables: No chain/target/match by that name - with tp11235 Linux - Kernel 10 03-24-2010 02:15 AM
iptables: No chain/target/match by that name schatoor Linux - Networking 6 01-04-2009 09:10 PM
userdefined chain in iptables yawe_frek Red Hat 2 11-28-2006 06:20 AM
iptables chain modification gizza23 Linux - Networking 2 07-10-2005 05:45 AM
iptables and LD chain spawing? lode Linux - Networking 8 04-21-2004 03:30 AM

All times are GMT -5. The time now is 08:13 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration