From: Dmitry Monakhov <dmonakhov@openvz.org>
To: Greg Freemyer <greg.freemyer@gmail.com>
Cc: linux-ext4@vger.kernel.org, Jan Kara <jack@suse.cz>,
OHSM-DEV <ohsm-devel@lists.sourceforge.net>
Subject: Re: [PATCH 08/11] ext4: introduce subtree logic
Date: Tue, 09 Feb 2010 13:06:22 +0300 [thread overview]
Message-ID: <874olqpvtt.fsf@openvz.org> (raw)
In-Reply-To: <87f94c371002081554k3e4d6019q332602fea344ccc9@mail.gmail.com> (Greg Freemyer's message of "Mon, 8 Feb 2010 18:54:37 -0500")
Greg Freemyer <greg.freemyer@gmail.com> writes:
> On Mon, Feb 8, 2010 at 8:28 AM, Dmitry Monakhov <dmonakhov@openvz.org> wrote:
>> * Abstract
>> A subtree of a directory tree T is a tree consisting of a directory
>> (the subtree root) in T and all of its descendants in T.
>>
>> Subtree feature allows to create an isolated (from user point of view)
>> trees.
>>
>> Subtree assumptions:
>> (1) Each inode has subtree id. This id is persistently stored inside
>> inode (xattr, usually inside ibody)
>> (2) Subtree id is inherent from parent directory
>> (3) Inode can not belongs to different subtree
>> Otherwise changes in one subtree result in changes in other subtree
>> which contradict to isolation criteria.
>>
>> This feature is similar to project-id in XFS. One may assign some id to
>> a subtree. Each entry from the subtree may be accounted in directory
>> subtree quota. Will appear in later patches.
>>
>> * Disk layout
>> Subtree id is stored on disk inside xattr usually inside ibody.
>> Xattr is used only as a data storage, It has not user visiable xattr
>> interface.
>>
>> Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org>
>
> Dmitry,
>
> I think the idea of subtrees is useful, but I'm curious about other
> use cases than just quota.
>
> At first glance you are attempting to create a generic subtree
> functionality for ext4, but criteria 3) above says a inode can only be
> in one subtree at a time.
Theoretically this is possible, but this dramatically complicate things
Just think about this. If inode belongs to different subtrees then
it must have several tree-dquota objects attached to it. This means
that quota require great quota redesign.
Obviously i don't know any use case for this feature. do you know any?
IMHO isolated subtrees has well defined use-cases. Wat's why two
independent teams (xfs-team and openvz) implemented this feature
in semantically identical way.
>
> Thus if quota utilizes subtrees and another future feature were to use
> subtrees and the layout of the subtree details were not identical,
> they would collide. Thus with the current patch you can only have one
> subtree dependent feature at a time for a given filesystem.
>
> It seems you need something along the lines of a subtree name space
> etc. in order to allow orthogonal service users to create orthogonal
> subtrees.
>
> Also, I can envision use cases where you have subtrees within subtrees.
>
> Envision a projects folder that forms one subtree, but one specific
> project within that folder needs to be in its own subtree. If I read
> your patch description right, that is not allowed because only
> directories of subtree 0 are allowed to contain diverging subtrees.
Default tree (ID == 0) is just analog of common space.
where other subrees exist. It is used for subtree manipulation.
>
> ie. A directory of subtree 0 can contain a directory of subtrees 1
> and 2, but a directory of subtree 10 is not allowed to contain
> subtrees 11 and 12.
>
> Just food for thought.
>
> Greg
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" 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:[~2010-02-09 10:06 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-08 13:28 [PATCH 00/11] [RFC] Introduce subtree quota support This patch set introduce subtree and subtree-quota support for ext4 Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 01/11] ext4: mount flags manipulation cleanup Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 02/11] ext4: trivial quota cleanup Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 03/11] quota: sb_quota state flags cleanup Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 04/11] quota: generalize quota transfer interface Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 05/11] quota: introduce get_id callback Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 06/11] quota: add generic subtree quota support Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 07/11] ext4: enlarge mount option field Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 08/11] ext4: introduce subtree logic Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 09/11] ext4: subtree add kconfig options Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 10/11] ext4: add subtree support Dmitry Monakhov
2010-02-08 13:28 ` [PATCH 11/11] ext4: add subtree quota support Dmitry Monakhov
2010-02-09 0:10 ` [PATCH 09/11] ext4: subtree add kconfig options Greg Freemyer
2010-02-08 23:54 ` [PATCH 08/11] ext4: introduce subtree logic Greg Freemyer
2010-02-09 10:06 ` Dmitry Monakhov [this message]
2010-02-09 13:36 ` Greg Freemyer
2010-02-09 13:53 ` Dmitry Monakhov
2010-02-09 14:29 ` Greg Freemyer
2010-02-09 14:48 ` Dmitry Monakhov
2010-02-09 14:52 ` Greg Freemyer
2010-02-09 15:21 ` Dmitry Monakhov
2010-02-09 0:49 ` Andreas Dilger
2010-02-09 9:29 ` Dmitry Monakhov
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=874olqpvtt.fsf@openvz.org \
--to=dmonakhov@openvz.org \
--cc=greg.freemyer@gmail.com \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=ohsm-devel@lists.sourceforge.net \
/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).