From owner-freebsd-fs@FreeBSD.ORG Sat Jan 23 02:33:31 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 C492810656B0 for ; Sat, 23 Jan 2010 02:33:31 +0000 (UTC) (envelope-from artemb@gmail.com) Received: from mail-gx0-f218.google.com (mail-gx0-f218.google.com [209.85.217.218]) by mx1.freebsd.org (Postfix) with ESMTP id 41D228FC0A for ; Sat, 23 Jan 2010 02:33:30 +0000 (UTC) Received: by gxk10 with SMTP id 10so1566726gxk.3 for ; Fri, 22 Jan 2010 18:33:30 -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:content-transfer-encoding; bh=F3ejol1Y1kdrODL4eODHKh1QoYC90FKB8qIhH5IyNGw=; b=k+a5PfOWRbAop/knUwy59JdDudNwhgMQOJt/dGXrHCRfeoGw+7cbWI6TOm7bXHSsUp iYCt3ibz36PTLY8eXF3+hqh68+Wl9F88J8ef8Emd0wHGcbTLZteGRqNbRg3MecRjWq9C +TzSL2pJKFCoS4oWV5UXzeO9Z8atvt+y/70n4= 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 :content-transfer-encoding; b=XzRsOCeU7JTP4v/iln6IF9NseyW8vyrfPsOArS8AH6LcS+OR+tBCKKsDQI+TLjX9qR IHxh+iXc8YUdAuMCdlhOU7bV0U3/iaTI/7G0nXy7xFqpthTlUnh7lVNmOwOaDjMUWSCR gCnW4ZCQcoDA0VZuIya9sNI52WF60u1k3zRM8= MIME-Version: 1.0 Sender: artemb@gmail.com Received: by 10.90.37.14 with SMTP id k14mr3469915agk.53.1264214010284; Fri, 22 Jan 2010 18:33:30 -0800 (PST) In-Reply-To: References: <4B58976E.1020402@polands.org> <4B58D4D3.80009@egr.msu.edu> <20100122042843.GA8858@polands.org> <1308c71eec426200d4c34b926bba8806.squirrel@email.polands.org> Date: Fri, 22 Jan 2010 18:33:29 -0800 X-Google-Sender-Auth: cd6c1080d9e31b03 Message-ID: From: Artem Belevich To: Doug Poland Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable 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:33:31 -0000 Ignore my previous email. Something else is probably at play here. If I were right, then you should have ended up with vm.kmem_size=3D8G. However, in your case it's 2G. Beats me why. You may want to get to the console prompt and check whether loader did set the values correctly before it boots the kernel. If it didn't, then there may be something wrong with your /boot/loader.conf. Unfortunately whatever errors loader prints are immediately erased by the boot menu, so it's hard to see what exactly is the problem. --Artem On Fri, Jan 22, 2010 at 6:24 PM, Artem Belevich wrote: >> % 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: > > =A0 =A0 =A0 =A0/* > =A0 =A0 =A0 =A0 * Limit kmem virtual size to twice the physical memory. > =A0 =A0 =A0 =A0 * This allows for kmem map sparseness, but limits the siz= e > =A0 =A0 =A0 =A0 * to something sane. Be careful to not overflow the 32bit > =A0 =A0 =A0 =A0 * ints while doing the check. > =A0 =A0 =A0 =A0 */ > =A0 =A0 =A0 =A0if (((vm_kmem_size / 2) / PAGE_SIZE) > cnt.v_page_count) > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0vm_kmem_size =3D 2 * cnt.v_page_count * PA= GE_SIZE; > > So, either comment out these lines or just set vm.kmem_size to > slightly below 8G. > > --Artem >