mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Molle Bestefich" <molle.bestefich@gmail.com>
To: "Theodore Tso" <tytso@mit.edu>
Cc: linux-kernel@vger.kernel.org, "Duane Griffin" <duaneg@dghda.com>
Subject: Re: ext3 corruption
Date: Sat, 12 Aug 2006 19:24:06 +0200	[thread overview]
Message-ID: <62b0912f0608121024y1dde66aavcbf4df04631772c4@mail.gmail.com> (raw)
In-Reply-To: <20060812163834.GA11497@thunk.org>

Theodore Tso wrote:
> > I'm especially worried about the "70058 files, 39754 blocks used (0%)"
> > message at the end of the e2fsck run.
>
> OK, so it looks like the primary block group descriptors got trashed,
> and so e2fsck had to fall back to using the backup block group
> descriptors.

Good to have backups.  It would be very useful to know whether e2fsck
contemplates writing those back as primary BGDs when it's done, but I
couldn't find that in the documentation.  Will it?

(Would be good to have the above information in the docs.  Perhaps in
a "what does this message mean?" section.)

(Such a section would also help a lot when confronted with the first
message: "Entry blah is a link to directory bluh. Clear? y/n".
Obviously I don't want to "clear" my data.  But why is e2fsck
confronting me with that question?  Is something wrong with it that it
should be cleared?)

> The summary information in the backup block group
> descriptors is not backed up, for speed/performance reasons.  This is
> not a problem, since that information can always be regenerated
> trivially from the pass 5 information.

Thanks for the information!
(Would be very helpful to have a copy/paste of the above in the docs too...)

> That's what all of "free inodes/blocks/directories count wrong"
> messages in your log were all about.

Ah, I'm relieved.  The sheer number of messages was an indicator to me
that e2fsck is doing something gruesomely wrong.

> The 39754 block used (0%) is just because you were using -n and the
> summary information is calculated from the filesystem summary data,
> not from the pass5 count information (which was thrown away since you
> were running -n and thus declined to fix the results).

Much relieved again, thanks.

I'm wondering why it even tries to use the corrupt information, instead of just:
* reconstructing it from scratch
* not asking the user?

That leaves me a little less relieved once again ;-).

> I can imagine accepting a patch which sets a flag if any discrepancies
> found in pass 5 are not fixed, and then if the summary information is
> requested,

Huh?  The user didn't request anything, it always prints.

> to print a warning message indicating that the summary
> information may not be correct.

Even not printing anything would probably be better than knowingly
printing wrong information...

> But no, it's not worth it to take
> into account changes that -n might make if the user had said "yes".
> The complexities that would entail would be huge, and in fact as it is
> e2fsck -n does give a fairly accurate report of what what is wrong
> with the filesystem.  Is it 100% accurate?  No, but that was never the
> goal of e2fsck -n.  If you want that, then use a dm-snapshot, and run
> e2fsck on the snapshot....

Agreed.  Running a r/w e2fsck on some kind of overlay would be the way
to implement a more useful (for me anyway) version of -n.

But I think dm-snapshot is useless in this case because:
 * It must be configured before MD is configured and the filesystem is
created, which I haven't done on this box.

And generally because:
 * It's rather good at corrupting the filesystems you store on top of
it *itself*...
 * Either you have to create snapshots on devices just as big as the
ones being snapshotted, or you'll have to live with the snapshot
failing any time because it's full.  There's no good management
framework to help you manage the full/failing situations either.

Thanks a lot for the information!

I take it that it's safe to run e2fsck on the filesystem, then...

  reply	other threads:[~2006-08-12 17:24 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-13 20:32 Molle Bestefich
2006-08-08 23:47 ` Molle Bestefich
2006-08-09  1:33   ` Sergio Monteiro Basto
2006-08-09 10:36   ` Molle Bestefich
2006-08-09 11:33   ` linux-os (Dick Johnson)
2006-08-09 15:22     ` Molle Bestefich
2006-08-09 15:38       ` Michael Loftis
2006-08-09 18:28         ` Molle Bestefich
2006-08-09 18:41           ` Mws
2006-08-09 20:17           ` Duane Griffin
2006-08-09 20:47             ` Molle Bestefich
     [not found]               ` <e9e943910608091527t3b88da7eo837f6adc1e1e6f98@mail.gmail.com>
2006-08-09 23:09                 ` Molle Bestefich
2006-08-10  0:08                   ` Duane Griffin
2006-08-10 21:00                     ` Molle Bestefich
2006-08-12 16:38                       ` Theodore Tso
2006-08-12 17:24                         ` Molle Bestefich [this message]
2006-08-12 21:47                           ` Theodore Tso
2006-08-13 19:21                             ` Molle Bestefich
2006-08-14  3:23                               ` Kyle Moffett
2006-08-14 15:34                               ` Theodore Tso
2006-08-14 17:21                                 ` Molle Bestefich
2006-08-10  3:06           ` Jim Crilly
2006-08-10  9:48             ` Molle Bestefich
2006-08-10 11:41               ` linux-os (Dick Johnson)
2006-08-10 12:21                 ` Molle Bestefich
2006-08-10 12:19               ` Helge Hafting
2006-08-10 13:00                 ` Molle Bestefich
2006-08-10 14:40                   ` gmu 2k6
2006-09-24  8:56                 ` Molle Bestefich
2006-09-25 12:27                   ` Helge Hafting
2006-10-02  2:40                     ` Molle Bestefich
2006-10-02  3:24                       ` Gene Heskett
2006-10-02  6:50                         ` Kyle Moffett
2006-08-10 16:10               ` John Stoffel
2006-08-10 19:10                 ` Molle Bestefich
2006-08-11  8:06                   ` Helge Hafting
2006-08-11 13:26                 ` Horst H. von Brand
2006-08-12  8:54                   ` Molle Bestefich
2006-08-12 10:31                     ` Molle Bestefich
2006-08-17  1:27                     ` Horst H. von Brand
2006-08-17 13:46                       ` Molle Bestefich
2006-08-10  8:32           ` Bernd Petrovitsch
2006-08-10  7:44       ` Denis Vlasenko
     [not found] <Pine.LNX.4.33.0207121337500.8654-100000@coffee.psychology.mcmaster.ca>
2002-07-12 19:05 ` Alec Smith
2002-07-12 20:11   ` Andrew Morton
  -- strict thread matches above, loose matches on Subject: below --
2002-07-12 15:32 Alec Smith
2002-07-12 15:52 ` Russell King
2002-07-12 19:51   ` Andrew Morton
2002-07-12 16:02 ` Alan Cox

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=62b0912f0608121024y1dde66aavcbf4df04631772c4@mail.gmail.com \
    --to=molle.bestefich@gmail.com \
    --cc=duaneg@dghda.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tytso@mit.edu \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®