From owner-freebsd-fs@FreeBSD.ORG Sun Oct 10 12:27:50 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 C7154106564A for ; Sun, 10 Oct 2010 12:27:50 +0000 (UTC) (envelope-from avg@freebsd.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 113FC8FC0A for ; Sun, 10 Oct 2010 12:27:49 +0000 (UTC) Received: from porto.topspin.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id PAA07568; Sun, 10 Oct 2010 15:27:24 +0300 (EEST) (envelope-from avg@freebsd.org) Received: from localhost.topspin.kiev.ua ([127.0.0.1]) by porto.topspin.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1P4uzs-000Hcq-Dv; Sun, 10 Oct 2010 15:27:24 +0300 Message-ID: <4CB1B12B.3010107@freebsd.org> Date: Sun, 10 Oct 2010 15:27:23 +0300 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.9) Gecko/20100918 Lightning/1.0b2 Thunderbird/3.1.4 MIME-Version: 1.0 To: Kostik Belousov References: <39F05641-4E46-4BE0-81CA-4DEB175A5FBE@free.de> <201010061732.o96HW2Vi005945@higson.cam.lispworks.com> <4CAF45A8.3020401@icyb.net.ua> <4CB18BC6.70305@freebsd.org> <20101010121532.GG2392@deviant.kiev.zoral.com.ua> In-Reply-To: <20101010121532.GG2392@deviant.kiev.zoral.com.ua> X-Enigmail-Version: 1.1.2 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: freebsd-fs@freebsd.org Subject: Re: Locked up processes after upgrade to ZFS v15 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, 10 Oct 2010 12:27:50 -0000 on 10/10/2010 15:15 Kostik Belousov said the following: > On Sun, Oct 10, 2010 at 12:47:50PM +0300, Andriy Gapon wrote: >> Hm, I think that we actually shouldn't see a stack like that. >> vm_fault sets VPO_BUSY on a page before calling vnode_pager_generic_getpages, so >> the thread gets stuck forever in zfs mappedread. >> It seems like the page that was seen as invalid in vm_fault becomes valid while >> call flow reaches mappedread. > The vnode is share-locked, and vm object lock is dropped and reacquired > several times until control reaches zfs_mappedread. This indeed allows > a window during which page might be read by other thread. But wouldn't a page still stay protected by VPO_BUSY all that time? I mean that the page shouldn't be read in and marked valid by other thread while it's flagged with VPO_BUSY. And, AFAICS, vm_fault has the page busy for the whole duration. > There are two possible routes to solve the issue: > 1. Provide zfs-specific VOP_GETPAGES(). > 2. Use my vm6 patch. Sigh. -- Andriy Gapon