>From: Theodore Ts'o <[EMAIL PROTECTED]>
> On Mon, Jun 27, 2005 at 10:42:10PM -0700, Elliott Mitchell wrote:
> > `tune2fs` happily allows the creation of shared journals, and the kernel
> > I've got happily allows mounting of filesystems utilizing a shared
> > journal. OTOH `e2fsck` explodes when being run on such filesystems,
> > whether or not they're clean.
> > 
> > Documenting whether shared journals are supported would be nice...
> 
> Does the kernel actually work with shared journalled turned on?  You
> have multiple filesystems all using a single journal, and it does the
> right thing?  I didn't think that worked at the moment...

At the very least 2.4.28 /appeared/ to mount filesystems using such
journals and replay the journal successfully. I won't claim it actually
works though.

> The problem with shared journals in general is that we need to handle
> replaying multiple journals in a sane fashion, even if one of the
> disks that is using a shared journal is temporarily unavailable.  This
> in practice means we need to be able to extract out the journal
> entries that pertains to a particular filesystem, and save it to
> persistent storage somewhere (which may be tricky if we haven't
> checked the root filesystem yet, so it is read-only and other
> filesystems haven't been mounted yet).

Perhaps this is an argument that attempting to mount a filesystem
read-write that uses a shared journal when the journal is non-empty is
an error. I'm unsure how difficult replaying merely the journal entries
for one filesystem is, but certainly if all filesystems using the journal
are available `e2fsck` shouldn't explode.

It shouldn't be difficult for `e2fsck` to at least handle the common
shared journal case where all filesystems are available. Simply find the
journal, replay all entries and then scan the filesystem if needed. Along
with this, `e2fsck` should be able to take a journal device as an
argument, with the effect of replaying all entries and giving an error if
any FS is unavailable.

How common is the case you're suggesting anyway? I'd guess pretty rare
since it is very dangerous.

> As far as I know the kernel-level replay code doesn't handle shared
> journals, either.   

2.4.28 does mount them without giving any error messages.

> But yeah, putting in a warning that shared journals don't quite work
> would be a good thing.

Warning in `tune2fs`.


-- 
(\___(\___(\______          --=> 8-) EHM <=--          ______/)___/)___/)
 \BS (    |         [EMAIL PROTECTED] PGP 8881EF59         |    )   /
  \_CS\   |  _____  -O #include <stddisclaimer.h> O-   _____  |   /  _/
    \___\_|_/82 04 A1 3C C7 B1 37 2A*E3 6E 84 DA 97 4C 40 E6\_|_/___/




-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to