All of lore.kernel.org
 help / color / mirror / Atom feed
From: Qunwei Chen <chenqunwei@yahoo.com>
To: netfilter@lists.netfilter.org
Subject: Re: sub interface filtering
Date: Fri, 04 Apr 2003 20:31:04 -0500	[thread overview]
Message-ID: <3E8E31D8.50801@yahoo.com> (raw)
In-Reply-To: 7C9884991ADAE0479C14F10C858BCDF50C6FF0@alderaan.smgtec.com

I tried the google for "Advanced Traffic and Routing Howto" but failed 
to find it. Does anyone have the location of this document?

Thanks in advance,

Qunwei

Daniel Chemko wrote:

>The Advanced Traffic and Routing Howto had everything I needed. It can
>show you how to setup its IP settings etc.. If you want to integrate
>into IPTables, the following example shows how simply this can be
>accomplished.
>
>$ ip address list
>1: lo: <LOOPBACK,UP> mtu 16436 qdisc noqueue 
>    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
>    inet 127.0.0.1/8 brd 127.255.255.255 scope host lo
>2: eth0: <BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast qlen 100
>    link/ether 11:11:11:11:11:11 brd ff:ff:ff:ff:ff:ff
>    inet 192.168.1.2/24 brd 192.168.1.255 scope global eth0
>    inet 192.168.1.111/32 scope global eth0
>3: eth1: <BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast qlen 100
>    link/ether 11:11:11:11:11:11 brd ff:ff:ff:ff:ff:ff
>    inet 192.168.2.1/24 brd 192.168.1.255 scope global eth1
>
>You notice that there are 2 addresses on the same interface eth0. I want
>to forward each IP address to a separate machine on a different subnet
>in this case, so I would do the following:
>
>iptables -t nat -A PREROUTING -j DNAT --destination 192.168.1.2 --to-
>destination 192.168.2.2
>
>iptables -t nat -A PREROUTING -j DNAT --destination 192.168.1.111 --to-
>destination 192.168.2.111
>
>You could have included "-i eth0" if you really wanted to, but unless
>you have the same IP address bolted to different interfaces, I don't see
>that mattering much. 
>
>
>-----Original Message-----
>From: Mike [mailto:mikeeo@msn.com] 
>Sent: Wednesday, April 02, 2003 12:34 PM
>To: Daniel Chemko; netfilter@lists.netfilter.org
>Subject: Re: sub interface filtering
>
>I hate to ask but do you have and example of using iproute2 for IP
>address aliases?
>
>Thanks,
>Mike
>
>
>  
>




  reply	other threads:[~2003-04-05  1:31 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-02 20:45 sub interface filtering Daniel Chemko
2003-04-05  1:31 ` Qunwei Chen [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-04-07 16:48 Daniel Chemko
2003-04-02 19:53 Daniel Chemko
2003-04-02 20:34 ` Mike
2003-04-02 20:50   ` Kelly Setzer
2003-04-03  7:10   ` Ralf Spenneberg
2003-04-02 18:45 Mike
2003-04-02 19:20 ` Martijn Lievaart
2003-04-02 19:38 ` Rob Sterenborg
2003-04-02 20:56 ` Joel Newkirk
2003-04-03 15:49   ` Mike
2003-04-03 16:42     ` Joel Newkirk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3E8E31D8.50801@yahoo.com \
    --to=chenqunwei@yahoo.com \
    --cc=netfilter@lists.netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.