Feature #185
closedmds: set file layout policy on directory hierarchy
0%
Description
It woud be helpful to have a way to specify multiple files' object sizes. Currently there is an ioctl for controlling individual file block sizes. However, there is nothing for setting object size between global scope (tweaking config.cc's g_default_file_layout) and individual file. It may make sense to specify this for an entire directory at a time, e.g. with an xattr.
Example use case: I am presently evaluating Hadoop with Ceph as a base file system. Sage noted the state of block size specifying to me, and suggested xattr may be the way to go.
Updated by Alex Nelson almost 14 years ago
One complication that may arise: If directory xattrs are what are used, what would be the semantics of a file hard-linked under directories with different object sizes specified?
Updated by Sage Weil almost 14 years ago
Alex Nelson wrote:
One complication that may arise: If directory xattrs are what are used, what would be the semantics of a file hard-linked under directories with different object sizes specified?
The striping parameters (incl object size) are set on file creation, at which point there is only one link.
Updated by Sage Weil almost 14 years ago
If we use an xattr for this, one issue will be keeping the ancestor directly policy consistent across any mds node managing a subtree nested beneath that point. We probably don't want to require that all parent xattrs be readable in order to create new files.
Make xattrs aggressively rereplicated across nodes after update? Or, just use xattrs as interface, but manage the "policy" separately and aggressively replicate that across nodes?
Updated by Sage Weil over 13 years ago
- Subject changed from Support multi-file object size adjustment to mds: set file layout policy on directory hierarchy
Updated by Greg Farnum over 13 years ago
- Status changed from New to 4
Pushed server-side code to branch file_layouts. Compiled, not tested due to current lack of message-sending interface.
Updated by Greg Farnum over 13 years ago
- Status changed from 4 to In Progress
Going to branch the kclient too and write an ioctl plus a program to call it.
Updated by Greg Farnum over 13 years ago
- Status changed from In Progress to 4
Wrote the ioctl and updated test_ioctls to test it, then debugged issues with it. Still don't have any kind of ceph-manager tool or whatever, but I think that should be a separate issue.
In ceph commit:65b69f065ae755256d3abbbfd5d633e36cd3439b and ceph-client commit:9c448f311320827831daca99876ad4a7b419f70b
(these are just the file_layouts branches)
Updated by Greg Farnum over 13 years ago
- Status changed from 4 to Resolved
Pushed in 7aab70ddc464355f068a143ea0e972183c155f24 (userspace) and commit:f670ee7872e51842e817e1606539e3c72e4b31b7 (kernel).