From owner-freebsd-fs@FreeBSD.ORG Sat Jan 23 02:24:39 2010 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 06395106568D for ; Sat, 23 Jan 2010 02:24:39 +0000 (UTC) (envelope-from artemb@gmail.com) Received: from mail-yx0-f171.google.com (mail-yx0-f171.google.com [209.85.210.171]) by mx1.freebsd.org (Postfix) with ESMTP id AFC638FC14 for ; Sat, 23 Jan 2010 02:24:38 +0000 (UTC) Received: by yxe1 with SMTP id 1so1552301yxe.3 for ; Fri, 22 Jan 2010 18:24:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:in-reply-to :references:date:x-google-sender-auth:message-id:subject:from:to:cc :content-type; bh=Gx+rmDDGxSqgq6mzW+GwC5r5aYsSyREkaxpmeR2WhZ4=; b=pmKeAeYFw2wY7rBYx/eSXDTb1gjxWd+ndEE8ZiOE23sxH9eM3iThqkgCcBo4HVyGg6 OinfSKFkziI8ukHOm30GeO4z9ak6HKPi/2Ltvy1NJpEY7CEqdqegCRn3kkAR6bXEi+EM n0QneHGsZd0XAX24kgSpEBt7AX4xx3aCKl0MI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; b=oa6ICefPtR9CBQJ4GqhcSWIw0LtGsWLI/bTu4HkJ9cxN/TK9Ee+g+w7nGzDLN+xF3U ZrBLUfxybIOa9sVbjo8Bmp2G+iirUen10CardPCVp5E/d55Y1sNJ1QQlMA6u/SR/Uaub ESfKS4YTaGUTuIOR6DII3hoQMLd1Yr3w2upJI= MIME-Version: 1.0 Sender: artemb@gmail.com Received: by 10.91.17.25 with SMTP id u25mr3440954agi.68.1264213477703; Fri, 22 Jan 2010 18:24:37 -0800 (PST) In-Reply-To: <1308c71eec426200d4c34b926bba8806.squirrel@email.polands.org> References: <4B58976E.1020402@polands.org> <4B58BD2D.30803@rcn.com> <4B58D4D3.80009@egr.msu.edu> <20100122042843.GA8858@polands.org> <1308c71eec426200d4c34b926bba8806.squirrel@email.polands.org> Date: Fri, 22 Jan 2010 18:24:36 -0800 X-Google-Sender-Auth: b12ac356b4ebea0e Message-ID: From: Artem Belevich To: Doug Poland Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-fs@freebsd.org Subject: Re: Repeatable ZFS "kmem map too small" panic on 8.0-STABLE X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 23 Jan 2010 02:24:39 -0000 > % sysctl hw.physmem vm.kmem_size vm.kmem_size_max vfs.zfs.arc_max > > hw.physmem:4102688768 > vm.kmem_size: 2147483648 Here's your problem -- kmem_size is for some reason only 2G. Argh! I ran into that before. The code in sys/kern/kern_malloc.c intentionally limits kmem_size to twice the physical memory size: /* * Limit kmem virtual size to twice the physical memory. * This allows for kmem map sparseness, but limits the size * to something sane. Be careful to not overflow the 32bit * ints while doing the check. */ if (((vm_kmem_size / 2) / PAGE_SIZE) > cnt.v_page_count) vm_kmem_size = 2 * cnt.v_page_count * PAGE_SIZE; So, either comment out these lines or just set vm.kmem_size to slightly below 8G. --Artem