Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 26 Sep 2002 03:04:37 -0500 (CDT)
From:      Mike Silbersack <silby@silby.com>
To:        Giorgos Keramidas <keramida@ceid.upatras.gr>
Cc:        freebsd-net@freebsd.org
Subject:   Re: mbuf chain
Message-ID:  <20020926025730.J6503-100000@patrocles.silby.com>
In-Reply-To: <20020925090309.GC597@hades.hell.gr>

next in thread | previous in thread | raw e-mail | index | archive | help

On Wed, 25 Sep 2002, Giorgos Keramidas wrote:

> On 2002-09-24 13:57, Prafulla Deuskar <pdeuskar@FreeBSD.org> wrote:
> > All,
> >
> > Is there a pre-set limit on maximum number of fragments in a
> > mbuf chain ?
>
> Not as a limit of the mbuf chain code, but as a limit of the IP packet
> input code.  Look at the description of the ip_maxfragpackets sysctl
> value in src/sys/netinet/ip_input.c
>
> It is initialized by default to (nmbclusters / 4) in ip_init().
>
> The relevant code, that enforces the limit, is near the beginning of
> the ip_reass() function in the same file.
>
> Giorgos.

I don't believe that mbuf fragments have any relationship to IP
fragmentation.

And while you mention it, the IP fragmentation handling code is another
place where we need to add mbuf merging/chaining.

I've been thinking about this, actually.  How many IP fragments will a
packet ever truly have?  If you assume a 1500 byte ethernet packet broken
into 200 byte chunks, that's < 8.  If you break a jumbo frame into 1500
byte packets, that's < 7.  Can there be any normal use of fragmentation
that would produce more than 10 or so fragments?  Also, will overlapping
fragments really ever be seen, or can we just assume that's a sign of
abuse?

Sorry for the sudden change of direction for this thread, I've been
pondering how to improve our resistance to mbuf exhaustion through ip
frags.

Mike "Silby" Silbersack


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020926025730.J6503-100000>