Re: [PATCH][RFC] speeding up fsck -A

From: Theodore Ts'o (
Date: Mon Jul 21 2003 - 20:04:01 EST

On Mon, Jul 21, 2003 at 01:01:44AM +0200, Olaf Dietsche wrote:
> With this patch, I get a speedup of about 60%. During boot time it is
> even more. Can someone please tell me, why and when this WNOHANG was
> introduced. fsck seems to work fine without it.

This isn't a kernel problem; you should have just sent it to me
directly as an e2fsprogs maintainer, as documented in the README file
in the e2fsprogs source tree, or in /usr/shared/doc/e2fsprogs/README
on a Debian system, instead of bothering folks on the kernel list.

In any case, thanks for reporting this bug; I've fixed it
appropriately in the latest e2fsprogs sources. The WNOHANG was
introduced when I added support for the FSCK_MAX_INST environment
variable, which allows to user to constrain the maximum number of
child fsck's running at the same time, and FSCK_FORCE_ALL_PARALLEL.
What I needed to do was to call wait_one in blocking mode the first
time, and then call it in WNOHANG mode until all exited children have
been reaped. This is necessary so that fsck will start keep the
necesary number of children in parallel at the same time. What I did
instead was to always call it with WNOHANG always, which caused a
CPU-burning loop. Oops.

Anyway, this will be fixed in the next release, which will be soon at
this point....

                                                - Ted
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Wed Jul 23 2003 - 22:00:45 EST