From: Vivek Goyal <vgoyal@redhat.com>
To: Amir Goldstein <amir73il@gmail.com>
Cc: Miklos Szeredi <miklos@szeredi.hu>,
yangerkun <yangerkun@huawei.com>,
"zhangyi (F)" <yi.zhang@huawei.com>,
Miao Xie <miaoxie@huawei.com>,
overlayfs <linux-unionfs@vger.kernel.org>
Subject: Re: [QUESTION] problem about origin xattr
Date: Thu, 1 Feb 2018 10:25:43 -0500 [thread overview]
Message-ID: <20180201152543.GA12648@redhat.com> (raw)
In-Reply-To: <CAOQ4uxjxKjwjmJmHJPJfjHvkokVd0_4r5ENLXcs-8VnQ4eBBBQ@mail.gmail.com>
On Thu, Feb 01, 2018 at 01:26:58AM +0200, Amir Goldstein wrote:
[..]
> >> >> > ORIGIN vs REDIRECT seems to be the only major sticking point w.r.t
> >> >> > these patches at this point of time. As long as you and miklos agree
> >> >> > on that semantics, things will be fine.
> >> >>
> >> >> I think there are many problems with using ORIGIN for data.
> >> >>
> >> >> I also think it should not be difficult to generalize the REDIRECT
> >> >> code from directory to regular file. It should just be adding more
> >> >> conditions to create and handle redirects, no? The actual code is
> >> >> already there, because we do it for directories.
> >> >
> >> > I guess so. We already are doing it for directories so we should be
> >> > able to extend it for regular files too. I don't know enough to be
> >> > able to say what affect this will have on performance.
> >> >
> >> >>
> >> >> So what's the issue with lowerstack[0]? Can't we just use the same
> >> >> object for both purposes (i.e. the one found by going down the stack,
> >> >> just like for directories)?
> >> >
> >> > I think we should be able to. But then it seems to make ORIGIN redundant.
> >> > Because currently we are using ORIGIN to retrieve lowerstack[0]. And if
> >> > we change that, that means I will have to rip out ORIGIN logic altogether.
> >> > Its a relatively bigger change. So wanted to figure out is that what
> >> > we are looking for.
> >>
> >> Don't rip out ORIGIN logic, just disable it when we find METACOPY.
> >>
> >> So logic should be:
> >>
> >> - check METACOPY xattr, if exists continue to lower layers just like
> >> non-opaque directory
> >> - otherwise use ORIGIN xattr, just like we used to
>
> Careful there, when following metacopy by path, you also need to apply
> ovl_verify_lower() logic for indexed files, i.e. all files with nfs_export
> and lower hardlinks with index=on. same as I did for merge dir lookup
> with nfs_export.
Hmm..., so for metacopy files, if ORIGIN fh does not match the lower found
in lowerstack[0] what do we do. Return -ESTALE?
Vivek
next prev parent reply other threads:[~2018-02-01 15:25 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-31 10:36 [QUESTION] problem about origin xattr yangerkun
[not found] ` <CAOQ4uxhGmD2g4Z9EY504OfssyiVvUskKGec0vqraHOHia88PPQ@mail.gmail.com>
[not found] ` <20180131152041.GA8087@redhat.com>
2018-01-31 15:38 ` Amir Goldstein
2018-01-31 15:46 ` Vivek Goyal
2018-01-31 15:58 ` Amir Goldstein
2018-01-31 16:10 ` Miklos Szeredi
2018-01-31 16:55 ` Vivek Goyal
2018-01-31 18:08 ` Miklos Szeredi
2018-01-31 19:05 ` Vivek Goyal
2018-01-31 19:59 ` Amir Goldstein
2018-01-31 20:34 ` Vivek Goyal
2018-01-31 20:48 ` Miklos Szeredi
2018-01-31 20:58 ` Vivek Goyal
2018-01-31 21:06 ` Miklos Szeredi
2018-01-31 21:12 ` Vivek Goyal
2018-01-31 23:26 ` Amir Goldstein
2018-02-01 15:25 ` Vivek Goyal [this message]
2018-02-01 16:22 ` Amir Goldstein
2018-02-01 3:57 ` yangerkun
2018-02-01 5:37 ` Amir Goldstein
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180201152543.GA12648@redhat.com \
--to=vgoyal@redhat.com \
--cc=amir73il@gmail.com \
--cc=linux-unionfs@vger.kernel.org \
--cc=miaoxie@huawei.com \
--cc=miklos@szeredi.hu \
--cc=yangerkun@huawei.com \
--cc=yi.zhang@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.