All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Thhoep" <thhoep@gmx.de>
To: Ramin Dousti <ramin@cannon.eng.us.uu.net>
Cc: Ramin Dousti <ramin@cannon.eng.us.uu.net>, netfilter@lists.netfilter.org
Subject: Re: Iproute2 and fwmark usage
Date: Fri, 9 Jan 2004 20:06:33 +0100	[thread overview]
Message-ID: <001101c3d6e3$cdf03e60$1684188d@Kiste> (raw)
In-Reply-To: 20040109194247.GD24304@cannon.eng.us.uu.net

> > for marking i use:
> > "iptables -t mangle -A PREROUTING -i eth4 -s 192.168.0.22 -d
141.24.12.2 -j
> > MARK --mark-with 1"
> >
> > for selecting a routing table upon that marking i use:
> > "ip rule add fwmark 1 table test"
> >
> OK. Are these two instructions the only instructions active on the box?


besides of the marking there is a masquerading active, as mentioned in
previous mails:
"iptables -t nat -A POSTROUTING -o ppp4 -j MASQUERADE"

filter table is empty.

there exist other routing rules, but they are all rules from other hosts out
into the world. no rules backward, for internet-lan-direction i use the main
table.


> Both:
> "ip rule add fwmark 1 table test"
> and
> "ip rule add from 192.168.0.22 table test"
>
> are being used for the ping packets and seem to be equivalent. Your
problem
> seems to be the loss of the pong packets, right?

right

> >  tcpdump verifies, that indeed replies are coming in and shows, that no
icmp
> > error messages are sent out, what should be the case if no route back
could
> > be found due to incorrect routing.
>
> This part is not completely correct. The ICMP messages would go out
through
> ppp0, right? and you're not capturing that.
>
> Do a simultanious tcpdump on all the ppp interfaces and let us know the
result.

ok, i did monitor all interfaces using
"tcpdump -n -i ppp0 icmp and host 141.24.12.2"
and so on. as expected nowhere a pong went out. i think any pong leaving the
box would have showed up in the FORWARD counting rule in the first test.

> Although, with the output of "ip rule" it looks to me that table main must
be
> taken for the return traffic and you have a route to 192.168.0.0/24 there.

you are right. and _all_ routing tables contain a route to the local net, so
a packet should always find its way from the outside in. i think even if the
masquerading would be broken, the packet wouldnt get lost. it would show up
somewhere OR an icmp error would be sent to its sender. so is there a bug in
the routing code? and why am i then the only one having this problem?




  reply	other threads:[~2004-01-09 19:06 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-08 23:05 Iproute2 and fwmark usage Thhoep
2004-01-09 16:47 ` Ramin Dousti
2004-01-09 16:17   ` Thhoep
2004-01-09 17:35     ` Ramin Dousti
2004-01-09 16:50       ` Thhoep
2004-01-09 19:42         ` Ramin Dousti
2004-01-09 19:06           ` Thhoep [this message]
2004-01-09 20:47             ` Ramin Dousti
2004-01-09 20:09               ` Thhoep
2004-01-09 21:22                 ` Ramin Dousti
2004-01-09 21:30                   ` Thhoep
2004-01-09 22:02                     ` Thhoep
2004-01-11 20:57                       ` Thhoep
2004-01-11 21:07                         ` Antony Stone
2004-01-11 21:50                           ` Thhoep
2004-01-11 23:12                             ` Thhoep
2004-01-11 23:22                               ` Antony Stone
2004-01-13 23:46                               ` Thhoep
  -- strict thread matches above, loose matches on Subject: below --
2004-01-08 14:20 Filter out broadcast messages Gabby James
2004-01-08 14:31 ` iproute2 and fwmark usage Thhoep

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='001101c3d6e3$cdf03e60$1684188d@Kiste' \
    --to=thhoep@gmx.de \
    --cc=netfilter@lists.netfilter.org \
    --cc=ramin@cannon.eng.us.uu.net \
    /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.