Skip site navigation (1)Skip section navigation (2)
Date:      02 Nov 1999 15:58:51 +0200
From:      Giorgos Keramidas <keramida@ceid.upatras.gr>
To:        freebsd-questions@freebsd.org
Subject:   Re: increasing kern.maxproc without increasing maxuxsers?
Message-ID:  <86vh7lq9k4.fsf@localhost.hell.gr>
In-Reply-To: The Hermit Hacker's message of "Mon, 1 Nov 1999 19:56:31 -0400 (AST)"
References:  <Pine.BSF.4.10.9911011955230.30583-100000@thelab.hub.org>

next in thread | previous in thread | raw e-mail | index | archive | help
The Hermit Hacker <scrappy@hub.org> writes:

> Is this possible?  I can't seem to find any 'MAXPROC' ddefines in the
> kernel sources, so I'm figuring I gottta be looking in the wrong place...

From the /usr/src/sys/i386/conf/GENERIC comments, you can read:

    # The `maxusers' parameter controls the static sizing of a number of
    # internal system tables by a complicated formula defined in param.c.
    #
    maxusers        10

which means that changing maxusers will not actually limit the maximum
number of simultaneously logged in users.  On the contrary, you can have 
as many logged in users as your system can afford without running out of 
resources.  However, the value of maxusers is used in calculating the
static sizes of some important kernel tables, and one of these is the
number of processes.

In file /usr/src/sys/compile/GENERIC/param.c we read:

    #define NPROC (20 + 16 * MAXUSERS)

so now you know why setting maxusers will also set the maximum number of 
processes, during kernel compiles.

-- 
Giorgos Keramidas, <keramida@ceid.upatras.gr>
"What we have to learn to do, we learn by doing." [Aristotle]


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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?86vh7lq9k4.fsf>