Go Job Hunting at the LQ Job Marketplace
Go Back > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Red Hat This forum is for the discussion of Red Hat Linux.


  Search this Thread
Old 01-29-2013, 10:23 AM   #1
Registered: Nov 2004
Location: Virginia, US
Distribution: Slackware 14.1 multilib
Posts: 112

Rep: Reputation: 22
iptables question

I have a machine that has 3 NICs serving as a GW (eth0, eth1, and eth2 I have one machine in each of and that I need to be able to access from the network. So my idea is to set up port forwarding so that all traffic sent to that port gets forwarded to the corresponding machine. For example if my GW is and I point a browser to it get forwarded to

How would I write the rule(s) to get this working. TIA.
Old 01-29-2013, 04:08 PM   #2
Registered: Nov 2007
Location: USA
Distribution: CentOS 5/6
Posts: 183

Rep: Reputation: 6
If it were me I would create a forward rule like this:

If protocol is TCP and destination is and destination port is 80 and state of connection is NEW,RELATED,ESTABLISHED
Then a NAT rule like so:

If protocol is TCP and destination is and destination port is 80
If is your default gateway you might look at installing Endian Firewall:



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 question jnojr Linux - Security 11 04-05-2012 03:50 PM
iptables question enrique_arong Linux - Networking 4 09-28-2004 02:51 PM
Question on IPTABLES brokenflea Linux - Networking 3 02-10-2004 10:53 PM
iptables Question gauge73 Linux - Networking 3 12-14-2003 01:02 AM
Question about iptables tontod Linux - Networking 3 06-10-2002 06:03 PM

All times are GMT -5. The time now is 02:34 AM.

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