From: Vivek Goyal <vgoyal@redhat.com>
To: Miklos Szeredi <miklos@szeredi.hu>, "Ernst, Eric" <eric.ernst@intel.com>
Cc: "mszeredi@redhat.com" <mszeredi@redhat.com>,
"kata-dev@lists.katacontainers.io"
<kata-dev@lists.katacontainers.io>,
Stefan Hajnoczi <stefanha@redhat.com>,
Amir Goldstein <amir73il@gmail.com>,
overlayfs <linux-unionfs@vger.kernel.org>
Subject: Re: Virtio-fs as upper layer for overlayfs
Date: Mon, 13 Jan 2020 14:56:51 -0500 [thread overview]
Message-ID: <20200113195651.GA9780@redhat.com> (raw)
In-Reply-To: <20200107160918.GB15920@redhat.com>
On Tue, Jan 07, 2020 at 11:09:18AM -0500, Vivek Goyal wrote:
> On Mon, Jan 06, 2020 at 08:58:23PM +0100, Miklos Szeredi wrote:
> > On Mon, Jan 6, 2020 at 7:35 PM Vivek Goyal <vgoyal@redhat.com> wrote:
> > >
> > > On Mon, Jan 06, 2020 at 05:27:05PM +0000, Ernst, Eric wrote:
> > >
> > > [CC linux-unionfs@vger.kernel.org and amir]
> > >
> > > > Hi Miklos,
> > > >
> > > > One of the popular use cases for Kata Containers is running docker-in-docker. That is, a container image is run which in turn will make use of a container runtime to do a container build.
> > > >
> > > > When combined with virtio-fs, we end up with a configuration like:
> > > > xfs/ext4 -> overlayfs -> virtio-fs -> overlayfs
> > > >
> > > > As discussed in [1], per overlayfs spec:
> > > > "The upper filesystem will normally be writable and if it is it must support the creation of trusted.* extended attributes, and must provide valid d_type in readdir responses, so NFS is not suitable."
> > > >
> > >
> > > I don't know exaactly the reasons why NFS is not supported as upper. Are
> > > above only two reasons? These might work with virtio-fs depending on
> > > underlying filesystem. If yes, should we check for these properties
> > > at mount time (instead of relying on dentry flags only,
> > > ovl_dentry_remote()).
> > >
> > > I feel there is more to it.
> >
> > NFS also has these automount points, that we currently can't cope with
> > in overlayfs. And there's revalidation, which we reject on upper
> > simply because overlayfs currently doesn't call ->revalidate() on
> > upper. Not that we would not be able to, it's just something that
> > probably needs some thought.
> >
> > Virtio-fs does not yet have the magic automount thing (which would be
> > useful to resolve inode number conflicts), but it does have
> > revalidate. In the virtio-fs case, not calling ->revalidate() should
> > not be a problem, so it's safe to try out this configuration by adding
> > a hack to disable the remote check in case of a virtio-fs upper.
>
> Here is a hack patch to provide an exception to allow virtiofs as upper
> filesystem for overlayfs.
>
> I can mount now but I get warning that upper does not support xattr, hence
> disabling index and metaocopy. Still need to test why that's the case. I
> thought xattr are supported on virtiofs.
I have pushed this patch on a branch in my repo for testing.
https://github.com/rhvgoyal/linux/commit/0a0c0e2d9986ecf445e1fdff45b51f37b98ac1e6
I can now mount overlayfs on top of virtiofs with this patch. It needs to
run virtiofsd with option "-o xattr" and also needs following patch for it
to work.
https://www.redhat.com/archives/virtio-fs/2020-January/msg00047.html
Thanks
Vivek
prev parent reply other threads:[~2020-01-13 19:58 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <7904C889-F0AC-4473-8C02-887EF6593564@intel.com>
2020-01-06 18:35 ` Virtio-fs as upper layer for overlayfs Vivek Goyal
2020-01-06 19:58 ` Miklos Szeredi
2020-01-06 22:24 ` eric.ernst
2020-01-07 9:48 ` Miklos Szeredi
2020-01-07 13:37 ` Vivek Goyal
2020-01-07 16:09 ` Vivek Goyal
2020-01-13 19:56 ` Vivek Goyal [this message]
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=20200113195651.GA9780@redhat.com \
--to=vgoyal@redhat.com \
--cc=amir73il@gmail.com \
--cc=eric.ernst@intel.com \
--cc=kata-dev@lists.katacontainers.io \
--cc=linux-unionfs@vger.kernel.org \
--cc=miklos@szeredi.hu \
--cc=mszeredi@redhat.com \
--cc=stefanha@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).