Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 07 May 1998 22:30:30 -0700
From:      David Greenman <dg@root.com>
To:        Chris Fanning <cfanning@jingoro.prevmed.sunysb.edu>
Cc:        freebsd-net@FreeBSD.ORG
Subject:   Re: MBUFs and IPFW revisited 
Message-ID:  <199805080530.WAA08726@implode.root.com>
In-Reply-To: Your message of "Fri, 08 May 1998 01:03:33 -0000." <199805080103.BAA25377@jingoro.prevmed.sunysb.edu> 

next in thread | previous in thread | raw e-mail | index | archive | help
>> >1. So, the question becomes, does configuring ipfw into the kernel change the
>> >behavior of NMBCLUSTERS or reset it somewhere?
>> 
>>    netstat -m reports current/peak. The 'current' should shrink as expected,
>> and the peak will indicate the most that have been in-use at one time since
>> the system was booted. Does this answer your question? netstat in -current
>> reports current/peak/max and is thus easier to figure out how many are
>> actually configured (max).
>
>Yes sir, it certainly does.
>
>I assumed it was current/max since the first time I ever looked at netstat -m
>was when peak == max.  So when it says 60% in use, it's referring to 60% of
>the peak?  That certainly didn't help my confusion either.  It seems a little
>strange, but OK.

   Yeah, it's certainly confusing. I added the "max" to netstat recently in
an effort to reduce the confusion.

>Makes sense if the buffers aren't allocated until they're used - which is
>why "peak" would never drop because they're not getting freed.  (If they
>were getting freed, we'd have to rename peak!)

   Right, they don't get allocated until they are needed, after which time
they are never completely freed (but of course can be reused as network
buffers). It's (CPU) expensive to coalesce the freed buffers into whole
pages in order to free them, so we don't.

>Next time maybe I'll look at the source code.  FreeBSD does come with sources
>right? :)

   Also called "documentation". :-)

-DG

David Greenman
Co-founder/Principal Architect, The FreeBSD Project

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?199805080530.WAA08726>