4.8-STABLE Kernel Panic with dummynet options.
Sergey A. Osokin
osa at freebsd.org.ru
Wed Apr 9 07:10:49 PDT 2003
On Wed, Apr 09, 2003 at 05:03:03PM +0300, Dmitry Pryanishnikov wrote:
> On Wed, 9 Apr 2003 15:13:53 +0400, Sergey A. Osokin wrote:
> >> options NMBCLUSTERS=1024
> >> options NMBUFS=4096
> >
> > What is the NMBUFS? You talk about NSFBUFS?
>
> Nope, there is NMBUFS - number of single mbufs vs NMBCLUSTERS for
> mbuf clusters. You can see current usage:
>
> root at atlantis# netstat -m
> 1080/2736/32768 mbufs in use (current/peak/max):
> 1010 mbufs allocated to data
> 70 mbufs allocated to packet headers
> 781/2434/16384 mbuf clusters in use (current/peak/max)
>
> (1st line for mbufs, 4th for mbuf clusters) and adjust both values in
> /boot/loader.conf:
>
> kern.ipc.nmbufs="32768" # Number of mbufs
> kern.ipc.nmbclusters="16384" # Number of mbuf clusters
>
> Note the following sanity check in kernel:
>
> /* Sanity checks */
> if (nmbufs < nmbclusters * 2)
> nmbufs = nmbclusters * 2;
>
> > AFAIK 1024 is very-very small value for NMBCLUSTERS.
>
> Well, it depends ;) Really, one of my routers shows the following:
>
> dmitry at cs37$ netstat -m
> 69/560/6144 mbufs in use (current/peak/max):
> 69 mbufs allocated to data
> 35/206/1536 mbuf clusters in use (current/peak/max)
>
> after uptime of 46 days (total traffic up to several Mbit/s, 6 network
> interfaces, dummynet in use).
>
> On Wed, 9 Apr 2003 16:00:46 +0400, Sergey A. Osokin wrote:
> >> And what about the HZ value?
> >
> > AFAIK its compile time option.
>
> It's also boot-time tunable long time ago, see 4.4-RELEASE release notes:
>
> The maxusers kernel configuration parameter is now a boot-time tunable
> variable. The kernel parameters derived from maxusers are now also
> tunables and can be overridden at boot-time. The hz parameter is also now
> ^^^^^^^^^^^^
> a tunable.
>
> So one can just set HZ to some reasonable value (200, 500, 1000 - it depends
> also) in loader.conf:
>
> kern.hz="200" # Clock interrupts per second
Looks like time to rewrite handbook/faq/tuning(7)/etc. :-)
--
Rgdz, /"\ ASCII RIBBON CAMPAIGN
Sergey Osokin aka oZZ, \ / AGAINST HTML MAIL
http://ozz.pp.ru/ X AND NEWS
/ \
More information about the freebsd-stable
mailing list