From owner-freebsd-fs@FreeBSD.ORG Mon Mar 7 09:49:30 2011 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 715E2106566B for ; Mon, 7 Mar 2011 09:49:30 +0000 (UTC) (envelope-from mm@FreeBSD.org) Received: from mail.vx.sk (mail.vx.sk [IPv6:2a01:4f8:100:1043::3]) by mx1.freebsd.org (Postfix) with ESMTP id 05B5B8FC0C for ; Mon, 7 Mar 2011 09:49:30 +0000 (UTC) Received: from core.vx.sk (localhost [127.0.0.1]) by mail.vx.sk (Postfix) with ESMTP id 23DCE13CFF6; Mon, 7 Mar 2011 10:49:29 +0100 (CET) X-Virus-Scanned: amavisd-new at mail.vx.sk Received: from mail.vx.sk ([127.0.0.1]) by core.vx.sk (mail.vx.sk [127.0.0.1]) (amavisd-new, port 10024) with LMTP id THAuO76QpApO; Mon, 7 Mar 2011 10:49:27 +0100 (CET) Received: from [10.0.3.3] (188-167-50-235.dynamic.chello.sk [188.167.50.235]) by mail.vx.sk (Postfix) with ESMTPSA id D002F13CFEB; Mon, 7 Mar 2011 10:49:26 +0100 (CET) Message-ID: <4D74AA26.10606@FreeBSD.org> Date: Mon, 07 Mar 2011 10:49:26 +0100 From: Martin Matuska User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.14) Gecko/20110223 Thunderbird/3.1.8 MIME-Version: 1.0 To: Jeremy Chadwick References: <1299232133.18671.3.camel@pc286.embl.fr> <20110304100517.GA23249@icarus.home.lan> In-Reply-To: <20110304100517.GA23249@icarus.home.lan> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: freebsd-fs@freebsd.org, =?UTF-8?B?TWlja2HDq2wgQ2Fuw6l2ZXQ=?= Subject: Re: kmem_map too small with ZFS and 8.2-RELEASE 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: Mon, 07 Mar 2011 09:49:30 -0000 In 8-STABLE (amd64), starting with SVN revision 214620 vm.kmem_size_scale defaults to 1. This means in 8.2-RELEASE, vm.kmem_size is automatically set to the amout of your system RAM, so vm.kmem_size="16G" is automatically set on a system with 16GB RAM. Dňa 04.03.2011 11:05, Jeremy Chadwick wrote / napísal(a): > On Fri, Mar 04, 2011 at 10:48:53AM +0100, Mickaël Canévet wrote: >>> I'd use vm.kmem_size="32G" (i.e. twice your RAM) and that's it. >> Should I also increase vfs.zfs.arc_max ? > You should adjust vm.kmem_size, but not vm.kmem_size_max. > > You can adjust vfs.zfs.arc_max to basically ensure system stability. > This thread is acting as evidence that there are probably edge cases > where the kmem too small panic can still happen despite the limited ARC > maximum defaults. > > For a 16GB system, I'd probably use these settings: > > vm.kmem_size="16384M" > vfs.zfs.arc_max="13312M" > > I would also use these two settings: > > # Disable ZFS prefetching > # http://southbrain.com/south/2008/04/the-nightmare-comes-slowly-zfs.html > # Increases overall speed of ZFS, but when disk flushing/writes occur, > # system is less responsive (due to extreme disk I/O). > # NOTE: Systems with 8GB of RAM or more have prefetch enabled by > # default. > vfs.zfs.prefetch_disable="1" > > # Decrease ZFS txg timeout value from 30 (default) to 5 seconds. This > # should increase throughput and decrease the "bursty" stalls that > # happen during immense I/O with ZFS. > # http://lists.freebsd.org/pipermail/freebsd-fs/2009-December/007343.html > # http://lists.freebsd.org/pipermail/freebsd-fs/2009-December/007355.html > vfs.zfs.txg.timeout="5" > > The advice in the Wiki is outdated, especially for 8.2-RELEASE. Best > not to follow it as of this writing. > >> Do you have any idea why the kernel panicked at only 8GB allocated ? > I do not. A kernel developer will have to comment on that. > > Please attempt to reproduce the problem. If you can reproduce it > reliably, this will greatly help kernel developers tracking down the > source of the problem. >