From owner-freebsd-fs@FreeBSD.ORG Sun Oct 7 18:43:59 2012 Return-Path: Delivered-To: fs@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5A0901065670; Sun, 7 Oct 2012 18:43:59 +0000 (UTC) (envelope-from gibbs@scsiguy.com) Received: from aslan.scsiguy.com (ns1.scsiguy.com [70.89.174.89]) by mx1.freebsd.org (Postfix) with ESMTP id 255A38FC08; Sun, 7 Oct 2012 18:43:58 +0000 (UTC) Received: from macbook.scsiguy.com (macbook.scsiguy.com [192.168.0.99]) (authenticated bits=0) by aslan.scsiguy.com (8.14.5/8.14.5) with ESMTP id q97Ihw7r084465 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Sun, 7 Oct 2012 12:43:58 -0600 (MDT) (envelope-from gibbs@scsiguy.com) Content-Type: text/plain; charset=iso-8859-1 Mime-Version: 1.0 (Mac OS X Mail 6.2 \(1499\)) From: "Justin T. Gibbs" In-Reply-To: <5071A071.1020800@FreeBSD.org> Date: Sun, 7 Oct 2012 12:44:02 -0600 Content-Transfer-Encoding: 7bit Message-Id: <97D56E7F-1284-4FB1-8C83-9EE04FE4F59F@scsiguy.com> References: <76CBA055-021F-458D-8978-E9A973D9B783@scsiguy.com> <506EB43B.8050204@FreeBSD.org> <5071A071.1020800@FreeBSD.org> To: Andriy Gapon X-Mailer: Apple Mail (2.1499) X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (aslan.scsiguy.com [192.168.0.4]); Sun, 07 Oct 2012 12:43:58 -0600 (MDT) Cc: Konstantin Belousov , Pawel Jakub Dawidek , fs@FreeBSD.org Subject: Re: ZFS: Deadlock during vnode recycling 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: Sun, 07 Oct 2012 18:43:59 -0000 On Oct 7, 2012, at 9:32 AM, Andriy Gapon wrote: > In fact here is a real patch that I would like to propose: > http://people.freebsd.org/~avg/zfs-getnewvnode_reserve.diff OS-X has these same types of problems and I talked with Don Brady of the OS-X ZFS port about them during ZFS day. It sounds like he explicitly pre-allocates vnodes in these code paths instead of relying on a reserve pool. I plan to review his work since I expect he's found and fixed problems we don't even know we have yet. My only complaint with this patch is that it doesn't include stats counters for these rare conditions so that I can validate that the code is exercised during a test suite. Can you merge in the kstat portion of the change I proposed? -- Justin