SMP on FreeBSD 6.x and 7.0: Worth doing?

Uwe Doering gemini at
Wed Dec 26 12:29:55 PST 2007

Mike Tancsa wrote:
> At 08:11 AM 12/26/2007, Scott Long wrote:
>>>         How does one know if the vfs.ufs.dirhash_maxmem is set too 
>>> high and are exhausting KVA ?
>> Panics, freezes, failure to exec new programs, failure to create 
>> pipes, etc.
> Is there anyway to know ahead of time one is getting close to the stage 
> where all those "bad things" start to happen ?

At least on FreeBSD 4.11 you can do

   sysctl -a|grep kvm

and get something like this:

   vm.kvm_size: 1065353216
   vm.kvm_free: 348127232

Perhaps this works on later versions of FreeBSD, too.

Now, if vm.kvm_free drops to 10% or so of vm.kvm_size and continues to 
fall, and vfs.ufs.dirhash_mem still hasn't hit the 
vfs.ufs.dirhash_maxmem limit, it's time to get concerned.  Of course, 
you can also use the vm.kvm_* values to dimension vfs.ufs.dirhash_maxmem 
properly in the first place.


Uwe Doering         |  EscapeBox - Managed On-Demand UNIX Servers
gemini at  |

More information about the freebsd-stable mailing list