All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Scott <GregScott@InfraSupportEtc.com>
To: lartc@vger.kernel.org
Subject: RE: [LARTC] PREROUTING doubts !!
Date: Fri, 28 Dec 2001 11:44:30 +0000	[thread overview]
Message-ID: <marc-lartc-100953986625559@msgid-missing> (raw)
In-Reply-To: <marc-lartc-100952775209878@msgid-missing>

> iptables -A PREROUTING -t nat -i eth1 ... -j REDIRECT --to-port 3128
> iptables -A PREROUTING -t mangle -i eth1..... -j mark 1

I don't think that will do what you want.  The first iptables command will
A(dd) an entry to the nat table.  Your second command adds an entry to the
mangle table.  So even though one command immediately follows the other in
your script, packets won't see them that way.  Do this  to see the order of
tests in your tables:

iptables -L -v -n -t nat
iptables -L -v -n -t mangle

I have never been clear about the exact order of tables/chains packets see
so I don't know which table they will traverse first.

- Greg



-----Original Message-----
From: Arindam Haldar [mailto:ahiam@yahoo.com]
Sent: Friday, December 28, 2001 2:29 AM
To: lartc@mailman.ds9a.nl
Subject: [LARTC] PREROUTING doubts !!


hi all,

i want 2 know if the follwing is correct

iptables -A PREROUTING -t nat -i eth1 ... -j REDIRECT --to-port 3128
iptables -A PREROUTING -t mangle -i eth1..... -j mark 1

the intention is to send http pkts first to transpaent squid else use 
routing based on cost & bandwidth !

will be very thanful to u 4 cealring this doubt

arindam haldar


_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://ds9a.nl/lartc/

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://ds9a.nl/lartc/

      reply	other threads:[~2001-12-28 11:44 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-12-28  8:40 [LARTC] PREROUTING doubts !! Arindam Haldar
2001-12-28 11:44 ` Greg Scott [this message]

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=marc-lartc-100953986625559@msgid-missing \
    --to=gregscott@infrasupportetc.com \
    --cc=lartc@vger.kernel.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.