From mboxrd@z Thu Jan 1 00:00:00 1970 From: Amir Goldstein Subject: Re: [PATCH v2 05/11] ovl: lookup redirect by file handle Date: Fri, 28 Apr 2017 13:45:00 +0300 Message-ID: References: <1493025256-27188-1-git-send-email-amir73il@gmail.com> <1493025256-27188-6-git-send-email-amir73il@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Return-path: Received: from mail-io0-f193.google.com ([209.85.223.193]:33178 "EHLO mail-io0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1422810AbdD1KpC (ORCPT ); Fri, 28 Apr 2017 06:45:02 -0400 Received: by mail-io0-f193.google.com with SMTP id k87so10144254ioi.0 for ; Fri, 28 Apr 2017 03:45:01 -0700 (PDT) In-Reply-To: Sender: linux-unionfs-owner@vger.kernel.org List-Id: linux-unionfs@vger.kernel.org To: Miklos Szeredi Cc: "linux-unionfs@vger.kernel.org" , Vivek Goyal On Fri, Apr 28, 2017 at 1:05 PM, Miklos Szeredi wrote: > On Fri, Apr 28, 2017 at 11:57 AM, Amir Goldstein wrote: >> On Fri, Apr 28, 2017 at 12:37 PM, Miklos Szeredi wrote: >>> On Fri, Apr 28, 2017 at 10:15 AM, Amir Goldstein wrote: >>> >>>> Well, we could add configuration options to decide if and how to follow >>>> and verify fh for non-dir, but: >>>> >>>> 1. We agreed that trying to follow fh for non-dir is a no-loose situation >>>> for !redirect and hot cache case and a probable win for redirect with >>>> cold case >>> >>> Okay. That also means that redirect is not actually needed for >>> non-dir. Well, except for the weird case of having to reconstruct a >>> reverse mapping after copying the layers in order to properly handle >>> copy up of hardlinks on the lower layer. But lets not care about that >>> for now (or ever, probably). >>> >> >> It's needed for when we can't lookup by fh: >> - lower has NULL uuid >> - !same_lower_sb (may be relaxed going forward) >> >> Heh, it's hard too keep track of it all ;-) > > Since this is only for constant inode, we really shouldn't need to > care about any of the above cases. It's also going to be needed for preserving hardlinks (even without copying layers) for !same_fs_with_uuid case. But that is not fixed by this series, so I can introduce "redirect non-dir on ovl_link() and ovl_rename()" in the next series. > > Lets keep things as simple as possible. > OK, so I'll handle lookup for all layer on samefs with uuid and leave the rest for later. And will store overlay.origin in any configuration, which may be FILEID_INVALID for lowers that don't support exportfs, so we can make use of it later. Amir.