From owner-freebsd-current@FreeBSD.ORG Thu Jun 19 01:49:49 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A338E37B401 for ; Thu, 19 Jun 2003 01:49:49 -0700 (PDT) Received: from HAL9000.homeunix.com (ip114.bella-vista.sfo.interquest.net [66.199.86.114]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0F42343FBF for ; Thu, 19 Jun 2003 01:49:49 -0700 (PDT) (envelope-from das@freebsd.org) Received: from HAL9000.homeunix.com (localhost [127.0.0.1]) by HAL9000.homeunix.com (8.12.9/8.12.9) with ESMTP id h5J8nlJa080503; Thu, 19 Jun 2003 01:49:47 -0700 (PDT) (envelope-from das@freebsd.org) Received: (from das@localhost) by HAL9000.homeunix.com (8.12.9/8.12.9/Submit) id h5J8nl3e080502; Thu, 19 Jun 2003 01:49:47 -0700 (PDT) (envelope-from das@freebsd.org) Date: Thu, 19 Jun 2003 01:49:47 -0700 From: David Schultz To: Peter Losher Message-ID: <20030619084947.GA80465@HAL9000.homeunix.com> Mail-Followup-To: Peter Losher , current@freebsd.org References: <20030617080628.H1802@farside.isc.org> <20030618083401.GA74409@HAL9000.homeunix.com> <20030619070830.U26075@farside.isc.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030619070830.U26075@farside.isc.org> cc: current@freebsd.org Subject: Re: Problems tuning kmem_map on 5.1-REL box. X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jun 2003 08:49:50 -0000 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