From: Theodore Tso <tytso@MIT.EDU>
To: Curt Wohlgemuth <curtw@google.com>
Cc: linux-ext4@vger.kernel.org
Subject: Re: PATCH ext4: fix to call_filldir
Date: Mon, 24 Nov 2008 16:51:47 -0500 [thread overview]
Message-ID: <20081124215146.GC20928@mit.edu> (raw)
In-Reply-To: <20081124182105.184338C977@localhost>
On Mon, Nov 24, 2008 at 10:21:05AM -0800, Curt Wohlgemuth wrote:
>
> [ Sorry: I mistakenly sent just the patch, with no explanation... ]
>
> I happened to find a bug running bonnie++-1.03a on an ext4 filesystem, when
> it complained about not being able to remove a file.
>
> Further investigation showed a problem with call_filldir(), which is not
> quite correct with respect to the same function in fs/ext3/dir.c. The patch
> below fixes this problem.
Um, how much testing have you done with this patch in place? The
change to call_filldir() was part of other changes in how
call_filldir() was called, and at least in the common case where
filldir() returns -EINVAL because there's not enough room in the
user's readdir buffer and the entry needs to be saved for the next
getdents() systemcall, the code is correct.
In fact, I haven't tried your patch, but I'm pretty certain that if
applied, it will cause directory entries to be dropped such that rm
-rf for large hierarchies will *always* fail because some files won't
get deleted becuase they won't be returned by readdir().
What kernel version were you running when you were testing ext4 using
bonnie? If you are using a kernel older than 2.6.28-rc2 (and newer
than 2.6.27-rc4), I would guess what you ran into was a known bug that
was fixed by commit 3c37fc86.
- Ted
next prev parent reply other threads:[~2008-11-24 21:55 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-24 18:21 PATCH ext4: fix to call_filldir Curt Wohlgemuth
2008-11-24 21:51 ` Theodore Tso [this message]
2008-11-24 22:59 ` Curt Wohlgemuth
2008-11-25 2:05 ` Theodore Tso
-- strict thread matches above, loose matches on Subject: below --
2008-11-24 18:18 Curt Wohlgemuth
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=20081124215146.GC20928@mit.edu \
--to=tytso@mit.edu \
--cc=curtw@google.com \
--cc=linux-ext4@vger.kernel.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.