From: Benny Halevy <bhalevy@primarydata.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: Boaz Harrosh <bharrosh@panasas.com>,
"J. Bruce Fields" <bfields@redhat.com>,
linux-nfs@vger.kernel.org
Subject: Re: [PATCH RFC v0 05/49] pnfsd: introduce pnfsd header files
Date: Wed, 02 Oct 2013 14:35:42 +0300 [thread overview]
Message-ID: <524C050E.4010102@primarydata.com> (raw)
In-Reply-To: <20131001133335.GB32431@infradead.org>
On 2013-10-01 16:33, Christoph Hellwig wrote:
> On Mon, Sep 30, 2013 at 06:05:18PM -0700, Boaz Harrosh wrote:
>> The pnfs protocol and people have plans to, allow a multi typed
>> layouts from the same super-block. It is a per file attribute.
>> It even allows a multi protocol access to the same file.
>> The only flag should be the presence of the layout_get vector
>> that should indicate support or lack of it.
>
> The current method doesn't help with that as it can return a single type
> only anyway. So in principle I agree with you, but the way to fix it is
> not to keep the method, but to make sure it returns a bitmap of
> supported layouts.
>
>>> - there should be a struct pnfs_operations, but it should be confined
>>> to fs/nfsd: each layout can be a separate loadable module and gets
>>> registered there. For the initial file layout that module is
>>> self-contained, but for e.g. block or objects it would have
>>> call into the filesystem through export_ops, although way lower level
>>> than the NFS XDR level, e.g. for block there would be one of to get
>>> the extent map, and one to allocate an extent.
>>>
>>
>> No! This does not make any sense. What you say does not fit any model of any
>> cluster filesystem today.
>>
>> - Again the FS can support any protocol.
>> - Only the FS understand the structure and layout of the file access. Any
>> other model is a specific implementation and breaks abstraction. The only true
>> abstraction is the LO_GET LO_RETURN LO_COMMIT DEVICE_INFO and LO_CB_RECALL. anything
>> else is making assumptions.
>>
>> There is a pnfs vector and it is at this abstraction level exactly.
>
> No, the problem is that the pnfs_export_operations are entirely at the
> wrong level, as I tried to explain. The right level is very different
> for the different layouts:
>
> - for files it needs to boil down to a:
>
> - get a list of devices
> - given an inode/offset return the layout
>
For loosely clustered files-layout file systems the MDS would also
need to handle LAYOUTCOMMIT, and also generate and handle layout recalls,
depending on how much of that we can do in a generic way and how much is
file system specific.
> - for block it's get a block map for a file / create an unwritten
> extent / convert it to written
Besides converting to written there is also de-allocation of provisionally
allocated extents and more advanced stuff for client assisted copy-on-write
where after allocation of uninitialized extents the client can commit
extents to the block map by replacing existing initialized extents with
new ones.
>
> - for object it seems (not too familar):
>
> - get a list of devices for this fs
> - given an inode/offset return the layout
> - tell the fs that I/O has finished
>
> As all the layouts operate on different data structures it makes sense
> to make the methods operate on those, and keep the boilerplate code
> including the XDR encoding/decoding in one single place.
>
> Now how these pnfsd object layout drivers communicate with the fs I
> don't have an opinion on until we see the actual code, maybe we need a
> pnfs_<layout>_ops if it's complicated enough.
The original design this patchset builds on called for implementing the
layout type specifics as library code and let file systems supporting pnfs
implement the high level pnfs methods and use the library for encoding
and decoding layout-type specific XDR and use other helpers if needed.
You're calling for a "back-end layout driver" kind of layer that will serve
the layout type and will call into the file system using lower level methods.
> For the files case that
> can just call into dlm directly currently as we have no other
> interesting cluster fs in tree it's a mood point. For block it's simple
> enough that I'd just add it to export_ops, if not by that time we redo
> the current get_blocks mess in a way that we can simply piggyback it on
> that which would be even easier.
>
On the same lines, I think that for now calling directly into exofs makes
the most sense as we have no other object based pnfs implementation.
>>> This way we alsod avoid the dependcy on nfsd in the filesystems that the
>>> cureent version introduces.
Yeah, I agree that this dependency can and should be taken care of.
>>
>> There is no "dependency on nfsd in the filesystems"
>
> The patchset as pulled will created a depency on nfsd.ko from gfs2.ko
>
yup, fs/nfsd/nfs4pnfsdlm.c exports pnfs_dlm_export_ops and implements
the respective methods. This does not really belong to nfsd but rather
to the fs/dlm module.
Benny
>> The only dependency the FS has is an import of some library routines
>> at exportfs that take an abstract layout and device descriptions and encode
>> them into an XDR buffer. But the FS knows nothing of the XDR and the
>> NFSD is free to unload at any moment without forcing the FS to unload
>> first or at all.
>> This is actually tested, in fact I do this all the time when I want to
>> start fresh and have NFSD close all resources on the FS.
>
> That's not what happens with the file layout as posted, and it's not
> something I want to see happen every, btw. In Linux we're all about
> proper abstractions, and letting a fs control all pnfs aspects directly
> instead of having common code is a receipe for tons of copy & pasted
> code full of different bugs if we ever get additional implementations of
> a layout. Not that I really expect any in tree as all the other
> "interested partied" have shown to be leechers that just want to keep
> their filesystems out of tree and most of the time as illegal propritary
> modules anyway.
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
next prev parent reply other threads:[~2013-10-02 11:35 UTC|newest]
Thread overview: 142+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-26 18:36 [PATCH RFC v0 0/49] pnfsd-dlm Benny Halevy
2013-09-26 18:39 ` [PATCH RFC v0 01/49] pnfsd: Define CONFIG_PNFSD Benny Halevy
2013-09-26 18:39 ` [PATCH RFC v0 02/49] pnfsd: define NFSDDBG_PNFS Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 03/49] pnfsd: return pnfs flags on exchange_id Benny Halevy
2013-09-26 21:55 ` J. Bruce Fields
2013-09-27 1:09 ` Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 04/49] pnfsd: don't set up back channel on create_session for ds Benny Halevy
2013-09-26 22:01 ` J. Bruce Fields
2013-09-27 1:20 ` Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 05/49] pnfsd: introduce pnfsd header files Benny Halevy
2013-09-29 11:43 ` Christoph Hellwig
2013-09-29 12:12 ` Benny Halevy
2013-09-29 12:13 ` Christoph Hellwig
2013-09-29 12:20 ` Benny Halevy
2013-09-29 12:21 ` Christoph Hellwig
2013-09-29 12:35 ` Christoph Hellwig
2013-09-30 15:23 ` Benny Halevy
2013-10-01 13:19 ` Christoph Hellwig
2013-10-01 1:05 ` Boaz Harrosh
2013-10-01 13:33 ` Christoph Hellwig
2013-10-02 11:35 ` Benny Halevy [this message]
2013-10-02 16:06 ` Christoph Hellwig
2013-10-01 20:30 ` J. Bruce Fields
2013-10-02 11:36 ` Benny Halevy
2013-10-02 16:07 ` Christoph Hellwig
2013-10-03 6:02 ` Benny Halevy
2013-10-03 9:55 ` Christoph Hellwig
2013-10-03 12:29 ` Benny Halevy
2013-10-03 12:37 ` Christoph Hellwig
2013-10-03 13:12 ` Ric Wheeler
2013-10-03 13:17 ` Christoph Hellwig
2013-10-03 13:18 ` Ric Wheeler
2013-10-03 14:19 ` Benny Halevy
2013-10-03 14:21 ` Christoph Hellwig
2013-10-03 14:24 ` Ric Wheeler
2013-10-03 14:38 ` Benny Halevy
2013-10-01 1:41 ` Boaz Harrosh
2013-10-01 19:43 ` J. Bruce Fields
2013-09-26 18:40 ` [PATCH RFC v0 06/49] pnfsd: define pnfs_export_operations Benny Halevy
2013-09-27 14:39 ` J. Bruce Fields
2013-09-29 10:53 ` Benny Halevy
2013-09-29 12:14 ` Christoph Hellwig
2013-09-26 18:40 ` [PATCH RFC v0 07/49] pnfsd: add pnfs export option Benny Halevy
2013-09-27 14:36 ` J. Bruce Fields
2013-09-29 10:51 ` Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 08/49] pnfsd: layout verify Benny Halevy
2013-09-27 14:44 ` J. Bruce Fields
2013-09-29 11:16 ` Benny Halevy
2013-10-01 20:38 ` J. Bruce Fields
2013-10-02 11:42 ` Benny Halevy
2013-10-01 22:12 ` J. Bruce Fields
2013-09-26 18:40 ` [PATCH RFC v0 09/49] pnfsd: initial stub Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 10/49] pnfsd: use sbid hash table to map super_blocks to devid major identifiers Benny Halevy
2013-10-01 22:14 ` J. Bruce Fields
2013-10-02 14:32 ` Benny Halevy
2013-10-02 15:24 ` J. Bruce Fields
2013-10-11 19:56 ` Christoph Hellwig
2013-10-13 6:11 ` Benny Halevy
2013-10-13 11:08 ` Christoph Hellwig
2013-10-13 12:44 ` Benny Halevy
2013-10-14 14:15 ` Christoph Hellwig
2013-09-26 18:40 ` [PATCH RFC v0 11/49] NFSD: introduce exp_xdr.h Benny Halevy
2013-09-29 12:15 ` Christoph Hellwig
2013-09-30 15:25 ` Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 12/49] pnfsd: get device list/info Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 13/49] pnfsd: filelayout: " Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 14/49] pnfsd: provide helper for xdr encoding of deviceid Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 15/49] pnfsd: add helper functions for identifying DS filehandles Benny Halevy
2013-09-26 18:40 ` [PATCH RFC v0 16/49] pnfsd: accept all ds stateids Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 17/49] DEBUG: nfsd: more client_lock asserts Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 18/49] pnfsd: nfs4_assert_state_locked Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 19/49] pnfsd: layout get Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 20/49] pnfsd: filelayout: layout encoding Benny Halevy
2013-09-29 12:16 ` Christoph Hellwig
2013-10-01 1:15 ` Boaz Harrosh
2013-10-01 13:34 ` Christoph Hellwig
2013-10-01 6:04 ` Benny Halevy
2013-10-02 14:27 ` Benny Halevy
2013-10-02 16:09 ` Christoph Hellwig
2013-09-26 18:41 ` [PATCH RFC v0 21/49] nfsd: no need to unhash_stid before free Benny Halevy
2013-10-11 19:37 ` Christoph Hellwig
2013-10-13 6:23 ` Benny Halevy
2013-10-13 19:28 ` J. Bruce Fields
2013-09-26 18:41 ` [PATCH RFC v0 22/49] nfsd: cleanup free_stid Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 23/49] pnfsd: layout state allocation Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 24/49] pnfsd: process the layout stateid Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 25/49] pnfsd: layout state per client tracking Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 26/49] pnfsd: layout state per file tracking Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 27/49] pnfsd: hash layouts on layout state Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 28/49] pnfsd: support layout segment merging Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 29/49] pnfsd: support layout_type attribute Benny Halevy
2013-09-29 12:17 ` Christoph Hellwig
2013-10-01 1:21 ` Boaz Harrosh
2013-10-01 8:32 ` Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 30/49] pnfsd: make pnfs server return layout_blksize when the client asks for it Benny Halevy
2013-09-26 18:41 ` [PATCH RFC v0 31/49] pnfsd: add support for per-file layout_types attribute Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 32/49] pnfsd: per block device dlm data server list cache Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 33/49] pnfsd: Add IP address validation to nfsd4_set_pnfs_dlm_device() Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 34/49] pnfsd: new nfsd filesystem file: pnfs_dlm_device Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 35/49] pnfsd: nfsd4_pnfs_dlm_getdeviter Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 36/49] pnfsd: nfsd4_pnfs_dlm_getdevinfo Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 37/49] pnfsd: make /proc/fs/nfsd/pnfs_dlm_device report dlm device list Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 38/49] pnfsd: nfsd4_pnfs_dlm_layoutget Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 39/49] pnfsd: DLM file layout only support read iomode layouts Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 40/49] pnfsd: add dlm file layout layout-type Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 41/49] pnfsd: dlm pnfs_export_operations Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 42/49] pnfsd: gfs2: use generic file layout pnfs operations vector Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 43/49] pnfsd: release state lock around iput in put_nfs4_file Benny Halevy
2013-09-29 12:19 ` Christoph Hellwig
2013-10-01 13:31 ` Benny Halevy
2013-10-01 13:37 ` Christoph Hellwig
2013-10-02 14:17 ` Benny Halevy
2013-10-02 15:26 ` J. Bruce Fields
2013-10-11 19:47 ` Christoph Hellwig
2013-10-13 6:26 ` Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 44/49] posix_acl: resolve compile dependency in posix_acl.h Benny Halevy
2013-09-29 12:19 ` Christoph Hellwig
2013-10-02 14:17 ` Benny Halevy
2013-10-02 14:36 ` [PATCH] " Benny Halevy
2013-10-09 22:41 ` Andrew Morton
2013-10-10 8:49 ` Benny Halevy
2013-09-26 18:42 ` [PATCH RFC v0 45/49] nfs: resolve compile dependency in nfs_xdr.h Benny Halevy
2013-09-29 12:19 ` Christoph Hellwig
2013-10-02 14:19 ` Benny Halevy
2013-09-26 18:43 ` [PATCH RFC v0 46/49] pnfsd: layout return generic implementation Benny Halevy
2013-09-26 18:43 ` [PATCH RFC v0 47/49] pnfsd: pnfs_expire_client Benny Halevy
2013-09-26 18:43 ` [PATCH RFC v0 48/49] pnfsd: return on close Benny Halevy
2013-09-26 18:43 ` [PATCH RFC v0 49/49] pnfsd: dlm set return_on_close to true Benny Halevy
2013-09-26 19:44 ` [PATCH RFC v0 0/49] pnfsd-dlm J. Bruce Fields
2013-09-26 20:06 ` Benny Halevy
2013-09-27 13:31 ` Boaz Harrosh
2013-09-27 13:34 ` Benny Halevy
2013-09-27 16:37 ` Boaz Harrosh
2013-09-27 20:19 ` Benny Halevy
2013-10-01 0:23 ` Boaz Harrosh
2013-10-01 0:29 ` Boaz Harrosh
2013-10-02 6:02 ` Benny Halevy
2013-09-29 11:42 ` Christoph Hellwig
2013-09-29 11:54 ` Benny Halevy
[not found] <1588761701.18.1380804942396.JavaMail.root@thunderbeast.private.linuxbox.com>
2013-10-03 12:58 ` [PATCH RFC v0 05/49] pnfsd: introduce pnfsd header files Matt W. Benjamin
2013-10-03 13:03 ` Christoph Hellwig
2013-10-04 3:14 ` Matt W. Benjamin
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=524C050E.4010102@primarydata.com \
--to=bhalevy@primarydata.com \
--cc=bfields@redhat.com \
--cc=bharrosh@panasas.com \
--cc=hch@infradead.org \
--cc=linux-nfs@vger.kernel.org \
/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).