* Add information about NMBCLUSTERS/mbufs

* Add another item to the standard sypnosis
This commit is contained in:
Chern Lee 2001-08-23 23:11:29 +00:00
parent fded897c40
commit bfe5032a69
Notes: svn2git 2020-12-08 03:00:23 +00:00
svn path=/head/; revision=10456

View file

@ -1,7 +1,7 @@
<!--
The FreeBSD Documentation Project
$FreeBSD: doc/en_US.ISO8859-1/books/handbook/config/chapter.sgml,v 1.21 2001/08/19 23:43:57 dd Exp $
$FreeBSD: doc/en_US.ISO8859-1/books/handbook/config/chapter.sgml,v 1.22 2001/08/22 05:37:48 murray Exp $
-->
<chapter id="config-tuning">
@ -79,7 +79,13 @@
<para>Understand the basics of Unix and FreeBSD (<xref
linkend="basics">).</para>
</listitem>
</itemizedlist>
<listitem>
<para>Be familiar with keeping FreeBSD sources up to date
(<xref linkend="cutting-edge">), and
the basics of kernel configuration/compilation
(<xref linkend="kernelconfig">).</para>
</listitem>
</itemizedlist>
</sect1>
<sect1 id="configtuning-initial">
@ -922,9 +928,32 @@ kern.maxfiles: 2088 -> 5000</screen>
<para><varname>kern.maxfile</varname>'s default value is
dictated by the <option>maxusers</option> option in your
kernel configuration file. <varname>kern.maxfiles</varname> grows
proportionally to the value of <option>maxusers</option>.</para>
proportionally to the value of <option>maxusers</option>.
When compiling a custom kernel, it is a good idea to
set this kernel configuration option according to
the uses of your system. From this number, the kernel
is given most of its pre-defined limits. Even though
a production machine may not actually have 256 users
connected as once, the resources needed may be similar to
a high-scale webserver.</para>
</sect3>
</sect2>
<sect2>
<title>Network Limits</title>
<para>The <varname>NMBCLUSTERS</varname> kernel configuration
option dictate the amount of network mbufs available to the
system. A heavily-trafficked server with a low number of MBUFs
will hinder FreeBSD's ability. Each cluster represents
approximately 2K of memory, so a value of 1024 represents 2
megabytes of kernel memory reserved for network buffers. A
simple calculation can be done to figure out how many are
needed. If you have a web server which maxes out at 1000
simultaneous connections, and each connection eats a 16K receive
and 16K send buffer, you need approximately 32MB worth of
network buffers to cover the webserver. A good rule of thumb is
to multiply by 2, so 32MBx2 = 64MB/2K = 32768.</para>
</sect2>
</sect1>
</chapter>