FreeBSD current, apache and php4 woes

Scott Long scottl at
Sat Nov 15 22:45:08 PST 2003

Claus Guttesen wrote:
> Hi.
>>>panic: kmem_malloc(4096): kmem_map too small:
>>>275251200 total allocated cpuid = 0; =
>>man tuning
>>You probably need to reset maxusers to 128 or so
>>manually since the
>>auto-tuning is doing the wrong thing. Although this
>>is usually a problem
>>on 4GB systems.
> I'll try to adjust it manually.
>>You aren't running any wierd nmbclusters/nmbufs
>>values, are you?
> Just a straight install and custom-kernel reg. NIC and
> Claus

You'll either want to raise the size of the kmem_map pool
(this is where kernel malloc and UMA get their allocations),
or decrease the maximum number of vnodes allowed (vnodes get
allocated out of the kmem_map and are likely depleating it
in your case).  I run into this constantly; we worked on
fixing it last spring by making the maxvnodes auto-tune itself
better, but that seems to no longer be enough.  Add one of
the two lines to /boot/loader.conf:



The first one is probably the better choice for you since
the very nature of what you are doing demands that you touch
a lot of vnodes.


More information about the freebsd-current mailing list