Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Thomas Jacob <jacob@internet24.de>
To: netfilter@lists.netfilter.org
Subject: Re: Asymmetric routing and connection tracking
Date: Tue, 07 Aug 2007 15:47:26 +0200	[thread overview]
Message-ID: <1186494447.28140.57.camel@localhost> (raw)
In-Reply-To: <46B87149.20505@linpro.no>

>   There are no rules that does stateful matching for traffic that is
>  forwarded between two routers.  Such rules are only applied for traffic
>  that is forwarded to an access LAN (like eth2).  Traffic that comes in
>  from a transit provider and are forwarded directly to another router is
>  only filtered based on simple source/destination matches in the IP.
> 
>   If such rules do not match, and the router is the last hop before a
>  packet reaches its destination, it will apply stateful matching.  But
>  this happens only for packets to/from access VLANs like eth2 in my
>  drawing.

So in the scenario described, R1 wouldn't do any stateful packet
filtering for packets to and from the internal server network? But
the connections will be added to the connection tracking table of
R1 nonetheless (unless you use the NOTRACK target
in raw), only not with an ESTABLISHED state which probably
means they timeout more often than needed and you have
more insert/remove actions over the connection tracking hash
table, maybe that's the source of your problem.

You could try the NOTRACK/raw thing on the (internal-)standby-router,
or you could route the packets of connections that have incoming data
from
R1 back out over R1 with a policy routing setup (+connmark) on R2.

>   I have several transit providers, but since it's not really relevant
>  for the problem (at least I don't think so) I didn't bother to draw
>  them.  You're right that using some form of VRRP could have been a
>  possible solution though if I had only one, so I should have mentioned
>  it.  Apologies.

OK that makes sense, otherwise this would be high
up on my list for "most complicated solution for a simple problem" :-)

  Thomas



  reply	other threads:[~2007-08-07 13:47 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-07  7:06 Asymmetric routing and connection tracking Tore Anderson
2007-08-07 11:59 ` Thomas Jacob
2007-08-07 13:19   ` Tore Anderson
2007-08-07 13:47     ` Thomas Jacob [this message]
2007-08-08  7:55       ` Tore Anderson

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=1186494447.28140.57.camel@localhost \
    --to=jacob@internet24.de \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox