Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 05 Feb 2006 11:45:17 -0500
From:      Chuck Swiger <cswiger@mac.com>
To:        Andrew Pantyukhin <infofarmer@gmail.com>
Cc:        FreeBSD Questions <questions@freebsd.org>
Subject:   Re: Trouble with resources under network load
Message-ID:  <43E62B9D.5040302@mac.com>
In-Reply-To: <cb5206420602041148x76816902j23abb0dc21809029@mail.gmail.com>
References:  <cb5206420602041148x76816902j23abb0dc21809029@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Andrew Pantyukhin wrote:
> I've got P4 box with 256Mb RAM. I want it to be able to
> forward 5Mbit/s between 500 PPTP clients (no crypto/
> compression) and our ISP. I understand we should
> probably get Cisco for this, or at least a higher-spec
> box, but I just want this setup to be kinda proof of concept.
> Complicated things can be done using cheap hardware
> and a good OS. Can't they?

Sure.  :-)

> ====================================================
> 
> I'm constantly stumbling upon some out-of-resources
> problems. Just to name a couple:
> 
> named[400]: client 10.32.23.92#1714:
> error sending response: not enough free resources
> 
> snmpd[806]: sysctl get: Cannot allocate memory
> 
> ====================================================
> 
> I have these in loader.conf and sysctl.conf:
> 
> kern.maxfiles=65536
> kern.maxfilesperproc=65536
> net.graph.maxdgram=65536
> net.graph.recvspace=65536
> kern.maxusers=512
> kern.ipc.maxpipekva=268435456
> net.graph.maxalloc=65536
[ ... ]
> What's wrong?

For one thing, if you've got a machine with 256MB of RAM, you cannot possibly be
able to dedicate 256MB just to kern.ipc.maxpipekva.  Likewise, a machine with
256MB of users would auto-tune kern.maxusers to ~100 or so, and kern.maxfiles
ought to be under 10000, if not half that.

You should revert to the defaults and make gradual tuning changes, if needed,
from there.

-- 
-Chuck



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?43E62B9D.5040302>