Re: [RFC PATCH ext3/ext4] orphan list corruption due bad inode

2007-06-05 Thread Vasily Averin
Christoph Hellwig wrote: > On Tue, Jun 05, 2007 at 10:11:12AM +0400, Vasily Averin wrote: return d_splice_alias(inode, dentry); } >>> Seems reasonable. So this prevents the bad inodes from getting onto the >>> orphan list in the first place? >> make_bad_inode() is called from ext3_re

Re: [RFC PATCH ext3/ext4] orphan list corruption due bad inode

2007-06-04 Thread Vasily Averin
Eric Sandeen wrote: > Vasily Averin wrote: >> Bad inode can live some time, ext3_unlink can add it to orphan list, but >> ext3_delete_inode() do not deleted this inode from orphan list. As result >> we can have orphan list corruption detected in ext3_destroy_inode(). > > Ah, I see - so you have c

Re: [RFC PATCH ext3/ext4] orphan list corruption due bad inode

2007-06-04 Thread Christoph Hellwig
On Tue, Jun 05, 2007 at 10:11:12AM +0400, Vasily Averin wrote: > >>return d_splice_alias(inode, dentry); > >> } > > Seems reasonable. So this prevents the bad inodes from getting onto the > > orphan list in the first place? > > make_bad_inode() is called from ext3_read_inode() that is called

Re: [RFC PATCH ext3/ext4] orphan list corruption due bad inode

2007-06-04 Thread Vasily Averin
Andrew Morton wrote: > On Mon, 04 Jun 2007 09:19:10 +0400 Vasily Averin <[EMAIL PROTECTED]> wrote: >> diff --git a/fs/ext3/namei.c b/fs/ext3/namei.c >> index 9bb046d..e3ac8c3 100644 >> --- a/fs/ext3/namei.c >> +++ b/fs/ext3/namei.c >> @@ -1019,6 +1019,11 @@ static struct dentry *ext3_lookup(struct

Re: [RFC PATCH ext3/ext4] orphan list corruption due bad inode

2007-06-04 Thread Andreas Dilger
On Jun 04, 2007 19:03 -0700, Andrew Morton wrote: > What caused those inodes to be bad, anyway? Memory allocation failures? This can happen if e.g. NFS has a stale file handle - it will look up the inode by inum, but ext3_read_inode() will create a bad inode due to i_nlink = 0. Cheers, Andreas

Re: [RFC PATCH ext3/ext4] orphan list corruption due bad inode

2007-06-04 Thread Eric Sandeen
Vasily Averin wrote: After ext3 orphan list check has been added into ext3_destroy_inode() (please see my previous patch) the following situation has been detected: EXT3-fs warning (device sda6): ext3_unlink: Deleting nonexistent file (37901290), 0 Inode 0101a15b7840: orphan list check fa

Re: [RFC PATCH ext3/ext4] orphan list corruption due bad inode

2007-06-04 Thread Andrew Morton
On Mon, 04 Jun 2007 09:19:10 +0400 Vasily Averin <[EMAIL PROTECTED]> wrote: > After ext3 orphan list check has been added into ext3_destroy_inode() (please > see my previous patch) the following situation has been detected: > EXT3-fs warning (device sda6): ext3_unlink: Deleting nonexistent file

[RFC PATCH ext3/ext4] orphan list corruption due bad inode

2007-06-03 Thread Vasily Averin
After ext3 orphan list check has been added into ext3_destroy_inode() (please see my previous patch) the following situation has been detected: EXT3-fs warning (device sda6): ext3_unlink: Deleting nonexistent file (37901290), 0 Inode 0101a15b7840: orphan list check failed! 0773 6f665f0