From: Goldwyn Rodrigues <rgoldwyn@suse.de>
To: ocfs2-devel@oss.oracle.com
Subject: [Ocfs2-devel] What's the need of OCFS2_INODE_MAYBE_ORPHANED?
Date: Wed, 15 Jan 2014 09:35:36 -0600 [thread overview]
Message-ID: <52D6AAC8.90107@suse.de> (raw)
In-Reply-To: <20140113154201.GD18208@localhost>
On 01/13/2014 09:42 AM, Joel Becker wrote:
> On Thu, Jan 09, 2014 at 11:27:15AM -0600, Goldwyn Rodrigues wrote:
>>>> Yes, I did not consider that.
>>>> How about using open locks ro_holders count to identify this? That may
>>>> just work. Thanks!
>>> One problem I see in using open lock for this is it could be late.
>>> Consider the scenario where node A removes the dentry and then the node
>>> crashes before trying the try_open_lock. Node B does the file close
>>> later but it doesn't know that the file was unlinked and doesn't do the
>>> clean up.
>>>
>>> To me it appears OCFS2_INODE_MAYBE_ORPHANED is necessary. Any delay it
>>> is causing must be addressed differently.
>>
>> No, I don't mean to remove the OCFS2_INODE_MAYBE_ORPHANED flag, but set
>> it conditionally in ocfs2_dentry_convert_worker() based on the value of
>> the open locks held.
>
> I'm confused by what you are attempting here. We hold the dentry lock
> until the final dpu() (see the comment in fs/ocfs2/dcache.c). We should
> never have ro_holders==0 unless we're flushing the entry from the
> dcache. Do you mean something else?
>
No, I meant exactly that and I thought wrong. However, the patch
reversals pointed out by Srini have helped.
Thanks for the inputs,
--
Goldwyn
prev parent reply other threads:[~2014-01-15 15:35 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-09 0:12 [Ocfs2-devel] What's the need of OCFS2_INODE_MAYBE_ORPHANED? Goldwyn Rodrigues
2014-01-09 1:29 ` Srinivas Eeda
2014-01-09 3:12 ` Goldwyn Rodrigues
2014-01-09 5:30 ` Srinivas Eeda
2014-01-09 10:23 ` Joel Becker
2014-01-09 13:35 ` Goldwyn Rodrigues
2014-01-13 15:39 ` Joel Becker
2014-01-09 15:44 ` Goldwyn Rodrigues
2014-01-09 16:06 ` Srinivas Eeda
2014-01-09 16:34 ` Goldwyn Rodrigues
2014-01-09 17:04 ` Srinivas Eeda
2014-01-09 17:27 ` Goldwyn Rodrigues
2014-01-13 15:42 ` Joel Becker
2014-01-15 15:35 ` Goldwyn Rodrigues [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=52D6AAC8.90107@suse.de \
--to=rgoldwyn@suse.de \
--cc=ocfs2-devel@oss.oracle.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