summaryrefslogtreecommitdiffstats
path: root/sys/conf
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1996-05-31 00:20:34 +0000
committerpeter <peter@FreeBSD.org>1996-05-31 00:20:34 +0000
commita6023afadfbb05340c7296f1384561e1ecce012e (patch)
treeb446a70fccaa7fb3b4a986f5104bd02c2d030856 /sys/conf
parentb46e8cf885570613bfe0bf9fff30d835444fbf0f (diff)
downloadFreeBSD-src-a6023afadfbb05340c7296f1384561e1ecce012e.zip
FreeBSD-src-a6023afadfbb05340c7296f1384561e1ecce012e.tar.gz
Add an option "EXTRA_VNODES" to cause an extra number of vnode structures
to be allocated at boot time. This is an expensive option, as they consume physical ram and are not pageable etc. In certain situations, this kind of option is quite useful, especially for news servers that access a large number of directories at random and torture the name cache. Defining 5000 or 10000 extra vnodes should cut down the amount of vnode recycling somewhat, which should allow better name and directory caching etc. This is a "your mileage may vary" option, with no real indication of what works best for your machine except trial and error. Too many will cost you ram that you could otherwise use for disk buffers etc. This is based on something John Dyson mentioned to me a while ago.
Diffstat (limited to 'sys/conf')
-rw-r--r--sys/conf/NOTES14
-rw-r--r--sys/conf/options3
-rw-r--r--sys/conf/param.c7
3 files changed, 20 insertions, 4 deletions
diff --git a/sys/conf/NOTES b/sys/conf/NOTES
index 5208535..35ce831 100644
--- a/sys/conf/NOTES
+++ b/sys/conf/NOTES
@@ -2,7 +2,7 @@
# LINT -- config file for checking all the sources, tries to pull in
# as much of the source tree as it can.
#
-# $Id: LINT,v 1.258 1996/05/13 04:38:10 nate Exp $
+# $Id: LINT,v 1.259 1996/05/17 09:42:46 jkh Exp $
#
# NB: You probably don't want to try running a kernel built from this
# file. Instead, you should start from GENERIC, and add options from
@@ -44,6 +44,16 @@ options CHILD_MAX=128
options OPEN_MAX=128
#
+# Under some circumstances it is useful to have an extra number of
+# vnode data structures allocated at boot time. In particular,
+# usenet news servers can benefit if there are enough vnodes to
+# cache the busiest newsgroup and overview directories. Beware that
+# this is an expensive option, it consumes physical non-pageable ram.
+# A busy news server may benefit from 10,000 extra vnodes or so.
+#
+options EXTRA_VNODES=1
+
+#
# A math emulator is mandatory if you wish to run on hardware which
# does not have a floating-point processor. Pick either the original,
# bogus (but freely-distributable) math emulator, or a much more
@@ -258,7 +268,7 @@ options PORTAL #Portal filesystem
options PROCFS #Process filesystem
options UMAPFS #UID map filesystem
options UNION #Union filesystem
-# THis DEVFS is experimental but seems to work
+# This DEVFS is experimental but seems to work
options DEVFS #devices filesystem
# Make space in the kernel for a MFS root filesystem. Define to the number
diff --git a/sys/conf/options b/sys/conf/options
index 47fede9..436932a 100644
--- a/sys/conf/options
+++ b/sys/conf/options
@@ -1,4 +1,4 @@
-# $Id: options,v 1.11 1996/05/05 02:26:57 pst Exp $
+# $Id: options,v 1.12 1996/05/11 04:39:37 bde Exp $
# Option name filename
@@ -29,6 +29,7 @@ SYSVMSG opt_sysvipc.h
UCONSOLE
# Options used only in param.c.
+EXTRAVNODES opt_param.h
NMBCLUSTERS opt_param.h
SHMMAXPGS opt_param.h
SHMMAX opt_param.h
diff --git a/sys/conf/param.c b/sys/conf/param.c
index f86e749..92c06c1 100644
--- a/sys/conf/param.c
+++ b/sys/conf/param.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)param.c 8.3 (Berkeley) 8/20/94
- * $Id: param.c,v 1.18 1996/05/02 14:19:18 phk Exp $
+ * $Id: param.c,v 1.19 1996/05/10 19:28:32 wollman Exp $
*/
#include "opt_sysvipc.h"
@@ -89,6 +89,11 @@ int maxfiles = NPROC*2; /* system wide open files limit */
int maxfilesperproc = NPROC*2; /* per-process open files limit */
int ncallout = 16 + NPROC; /* maximum # of timer events */
+#ifndef EXTRAVNODES
+#define EXTRAVNODES 0
+#endif
+int extravnodes = EXTRAVNODES; /* spare vnodes to allocate */
+
/* maximum # of mbuf clusters */
#ifndef NMBCLUSTERS
#define NMBCLUSTERS (512 + MAXUSERS * 16)
OpenPOWER on IntegriCloud