9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] IP_DF bit and broken connections
@ 2002-12-03 13:09 Fco.J.Ballesteros
  0 siblings, 0 replies; 2+ messages in thread
From: Fco.J.Ballesteros @ 2002-12-03 13:09 UTC (permalink / raw)
  To: 9fans

Hi,

we've found that if we dont disable the check for IP_DF bit while
processing a fragment in ip.c, then some of our connections break from
time to time.  By doing this change, everything seems to work fine for
us:

diff /n/dump/2002/1203/sys/src/9/ip/ip.c /sys/src/9/ip/ip.c
315c315
< 	if(eh->frag[0] & (IP_DF>>8)){
---
> 	if(0 && eh->frag[0] & (IP_DF>>8)){

The reason seems to be that some times when we connect through our
router, we get packet fragments which also carry the DF bit set.
Since we're not network gurus, we asked to our local network
programming guru and he suggested not to even look into the DF bit if
we're not gatewaying.

I don't think this is a `Plan 9 problem', but since it did forbid
us to keep our connections alive when going through some routers, I
thought it could be of help for others.


We'll continue tracing this problem. In case we find out anything,
we'll let you know.



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [9fans] IP_DF bit and broken connections
@ 2002-12-03 14:16 presotto
  0 siblings, 0 replies; 2+ messages in thread
From: presotto @ 2002-12-03 14:16 UTC (permalink / raw)
  To: nemo, 9fans

[-- Attachment #1: Type: text/plain, Size: 677 bytes --]

I'm confused.  The DF bit should only be set in packets that you are
forwarding to someone else, i.e., if you are acting as a router.
Is that what you are doing?

I can imagine a situation where our action is incorrect.  If you are
acting as a router and the system routing through you is setting
the DF bit in order to do mtu discovery and it is larger than your
mtu is less than the packet size, then we should be sending back an
icmp message saying that we couldn't fragment.  Otherwise the
connection can't go through.  Is this your situation?

The only other situation I can imagine is that we're somewhere
forgetting to zero out the bit when creating packets.

[-- Attachment #2: Type: message/rfc822, Size: 2173 bytes --]

From: Fco.J.Ballesteros <nemo@plan9.escet.urjc.es>
To: 9fans@cse.psu.edu
Subject: [9fans] IP_DF bit and broken connections
Date: Tue, 3 Dec 2002 14:09:47 +0100
Message-ID: <bd6954a17427f079cf673f2fa9a75f63@plan9.escet.urjc.es>

Hi,

we've found that if we dont disable the check for IP_DF bit while
processing a fragment in ip.c, then some of our connections break from
time to time.  By doing this change, everything seems to work fine for
us:

diff /n/dump/2002/1203/sys/src/9/ip/ip.c /sys/src/9/ip/ip.c
315c315
< 	if(eh->frag[0] & (IP_DF>>8)){
---
> 	if(0 && eh->frag[0] & (IP_DF>>8)){

The reason seems to be that some times when we connect through our
router, we get packet fragments which also carry the DF bit set.
Since we're not network gurus, we asked to our local network
programming guru and he suggested not to even look into the DF bit if
we're not gatewaying.

I don't think this is a `Plan 9 problem', but since it did forbid
us to keep our connections alive when going through some routers, I
thought it could be of help for others.


We'll continue tracing this problem. In case we find out anything,
we'll let you know.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-12-03 14:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-03 13:09 [9fans] IP_DF bit and broken connections Fco.J.Ballesteros
2002-12-03 14:16 presotto

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).