Problems tuning kmem_map on 5.1-REL box.
David Schultz
das at freebsd.org
Thu Jun 19 01:49:50 PDT 2003
On Thu, Jun 19, 2003, Peter Losher wrote:
> On Wed, 18 Jun 2003, David Schultz wrote:
>
> > To allow the kmem_map to exceed 200 MB, you'll also need to tweak
> > VM_KMEM_SIZE_MAX to (for example) '(1024 * 1024 * 1024)'. BTW,
> > the formula, which I stole from vmparam.h, is:
> >
> > min(max(VM_KMEM_SIZE, Physical memory/VM_KMEM_SIZE_SCALE), VM_KMEM_SIZE_MAX)
>
> Looks like I may have found some kind of error, adding this to my kernel
> config:
>
> # KVM
> options VM_KMEM_SIZE_SCALE="4"
> options VM_KMEM_SIZE_MAX="(1024 * 1024 * 1024)"
>
> (1024MB of KVM, 4096MB/4, 1024MB MAX KVM size)
>
> Cause the following warning and compile bomb:
>
> % config KVM_FIX
> WARNING: unknown option `*' removed from ../compile/KVM_FIX/opt_vm.h
This looks like a limitation of config(8).
> Changing the options to:
>
> # KVM
> options VM_KMEM_SIZE_SCALE="4"
> options VM_KMEM_SIZE_MAX="(1024*1024*1024)"
>
> Configs and compiles cleanly, but panics when rebooting with the new
> kernel:
>
> kmem_suballoc: bad status return of 3.
> panic: kmem_suballoc
That means there wasn't a large enough contiguous region for the
kmem_map. I guess I forgot to tell you that you also need to
adjust KVA_PAGES upwards so that the kernel has enough virtual
address space to fit the map. The following should do:
options KVA_PAGES=512
More information about the freebsd-current
mailing list