From: Andreas Dilger <adilger@sun.com>
To: lustre-devel@lists.lustre.org
Subject: [Lustre-devel] Sub Tree lock ideas.
Date: Tue, 03 Feb 2009 02:04:09 -0700 [thread overview]
Message-ID: <20090203090409.GT28818@webber.adilger.int> (raw)
In-Reply-To: <75012621-B9AB-4093-AC23-E6E2E28D774F@Sun.COM>
On Feb 03, 2009 01:24 -0500, Oleg Drokin wrote:
>>> Perhaps another useful addition would be to deliver multiple blocking
>>> and glimpse callbacks from server to the client in a single RPC (as a
>>> result of a readdir+ sort of operation inside a dir where many files
>>> have "entire file lock") (we already have aggregated cancels in the
>>> other direction).
>>
>> Well, I'm not sure how much batching we will get from this, since it
>> will be completely non-deterministic whether multiple independent
>> client requests can be grouped into a single RPC.
>
> It would be a lot of batching in many common usecases like "untar a
> file", "Create a working files for applications, all in same dir/dir tree".
Maybe I misunderstand, but all of this batching is in the case of a single
client that is doing operations to send to the MDS. What I was thinking
would be a rare case is batching from the server to the client when e.g.
a bunch of clients independently open a bunch of files that are in a
directory for which a client holds a STL.
In the latter case, since all of the RPCs are coming from different clients,
it is much harder for the server to group them together into a single RPC
to send to the STL client.
> From the above my conclusion is we do not necessarily need SubTree locks
> for efficient metadata write cache, but we do need it for other
> scenarios (memory conservation). There are some similarities in the
> functionality too, but also some differences.
>
> One particular complexity I see with multiple read-only STLs is every
> modifying metadata operation would need to traverse the metadata tree
> all the way back to the root of the fs in order to notify all possible
> clients holding STL locks about the change about to be made.
Sorry, I was only considering the case of a 1-deep STL (e.g. a DIR lock,
not the arbitrary-depth STL you originally described). In that case,
there is no requirement for more than a single level of STL to be
checked/cancelled if a client is doing some modifying operation therein.
This is no different than e.g. if a bunch of clients are holding the
LOOKUP lock on a directory that has a new entry in it.
Eric also had a proposal that the DIR lock would be a "hash extent" lock
instead of a single bit, so that it would be possible (via lock conversion)
to avoid cancelling all of the entries cached on a client when a single
new file is being added. Only the hash range of the entry being added
would need to be removed from the lock, either via a 3-piece lock split
(middle extent being cancelled) or via a 2-piece lock split (smallest
extent being cancelled).
Cheers, Andreas
--
Andreas Dilger
Sr. Staff Engineer, Lustre Group
Sun Microsystems of Canada, Inc.
next prev parent reply other threads:[~2009-02-03 9:04 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-21 20:49 [Lustre-devel] Sub Tree lock ideas Oleg Drokin
2009-01-26 10:08 ` Andreas Dilger
2009-01-28 4:39 ` Oleg Drokin
2009-02-02 22:50 ` Andreas Dilger
2009-02-03 6:24 ` Oleg Drokin
2009-02-03 9:04 ` Andreas Dilger [this message]
2009-02-03 9:39 ` Oleg Drokin
2009-02-03 15:01 ` Nikita Danilov
2009-02-03 19:05 ` Oleg Drokin
2009-02-03 19:12 ` Nikita Danilov
2009-02-03 19:25 ` Oleg Drokin
2009-02-04 14:39 ` Nikita Danilov
2009-02-05 17:01 ` Oleg Drokin
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=20090203090409.GT28818@webber.adilger.int \
--to=adilger@sun.com \
--cc=lustre-devel@lists.lustre.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 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.