Return-Path: linux-nfs-owner@vger.kernel.org Received: from mail-qa0-f48.google.com ([209.85.216.48]:52613 "EHLO mail-qa0-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965438Ab3HHOqz (ORCPT ); Thu, 8 Aug 2013 10:46:55 -0400 Received: by mail-qa0-f48.google.com with SMTP id o19so336962qap.0 for ; Thu, 08 Aug 2013 07:46:54 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <5202764C.2000709@redhat.com> References: <1375799403-28544-1-git-send-email-miklos@szeredi.hu> <1375799403-28544-5-git-send-email-miklos@szeredi.hu> <52015739.4050702@redhat.com> <5202764C.2000709@redhat.com> Date: Thu, 8 Aug 2013 16:46:54 +0200 Message-ID: Subject: Re: [PATCH 4/4] fuse: drop dentry on failed revalidate From: Miklos Szeredi To: Anand Avati Cc: Ric Wheeler , Al Viro , Brian Foster , David Howells , Eric Paris , Linux-Fsdevel , Kernel Mailing List , Linux NFS list , Trond Myklebust , Steven Whitehouse , "mszeredi@suse.cz" Content-Type: multipart/mixed; boundary=047d7b6788f4ac529804e370ba6c Sender: linux-nfs-owner@vger.kernel.org List-ID: --047d7b6788f4ac529804e370ba6c Content-Type: text/plain; charset=UTF-8 On Wed, Aug 7, 2013 at 6:31 PM, Anand Avati wrote: > Thanks for attaching the thread. Was very educative! I still do not quite > understand - will umount() still work when inode_permission()[->getattr()] > on the ancestors fail (with ESTALE etc.)? Several cases: 1) mountpoint was removed 2) mountpoint's ancestor removed 3) mountpoint or ancestor moved 1) and 3) would only cause revalidate to fail, not inode operations (permission or getattr) since the inodes of ancestors still exist. 2) could error out if the ->permission got to the server. I'm not sure it will and I don't have an NFS setup handy to test. So it doesn't necessarily work but it can be made to work, and as Linus pointed out, it might still be the least worst option. BTW, attaching a little fuse filesystem that I've been testing this with. It's read-only, but the point here is that the tree is modified *externally*, so that's not an issue. Thanks, Miklos --047d7b6788f4ac529804e370ba6c Content-Type: text/x-csrc; charset=US-ASCII; name="fuse_lo.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