lkml.org 
[lkml]   [2002]   [Nov]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [Ext2-devel] bug in ext3 htree rename: doesn't delete old name, leaves ino with bad nlink
From
Date
On Tue, 2002-11-05 at 13:24, chrisl@vmware.com wrote:
> Thanks again for the nice bug report.

Thanks for looking at it so quickly. I want ext3+htree to stabilise as
quickly as possible, and since I had a nice reproducible bug, I may as
well make the most of it.

> I think I understand the problem now. What happen was, in ext3_rename,
> it will first add the new entry to directory and then remove the
> old entry. In this case, when add a new entry to the directory
> cause a leaf node split. And the old entry is in the very same
> leaf node. After split, the old entry have been move to another
> leaf node. But ext3_rename still holding the old pointer and bh
> to the old leaf node.

Yes, I would have guessed that it was related to a tree split. The
interesting thing to me is that it happened twice in this particular
run, and yet it must be a fairly uncommon occurrence overall (otherwise
it would have been reported before). I wonder if it really is a rare
event, or it has just gone unnoticed?

> This also raise an interesting question, after split leave node,
> do we need to update the dentry cache for the change?

Update it in what way? In principle a rename is an atomic operation, so
other things shouldn't be able to observe the directory in an
intermediate state.

J


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:30    [W:0.056 / U:1.436 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site