All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: kernel list <linux-kernel@vger.kernel.org>,
	ext2-devel@lists.sourceforge.net
Subject: Re: ext3: bump mount count on journal replay
Date: Wed, 14 Jul 2004 22:32:58 +0200	[thread overview]
Message-ID: <20040714203258.GC25802@elf.ucw.cz> (raw)
In-Reply-To: <20040714200554.GR23346@schnapps.adilger.int>

Hi!

> > Currently, you get fsck "just to be sure" once every ~30 clean
> > mounts or ~30 hard shutdowns. I believe that hard shutdown is way more
> > likely to cause some disk corruption, so it would make sense to fsck
> > more often when system is hit by hard shutdown.
> > 
> > What about this patch?
> >
> > @@ -1484,9 +1485,11 @@
> >  	 * root first: it may be modified in the journal!
> >  	 */
> >  	if (!test_opt(sb, NOLOAD) &&
> > -	    EXT3_HAS_COMPAT_FEATURE(sb, EXT3_FEATURE_COMPAT_HAS_JOURNAL)) {
> > -		if (ext3_load_journal(sb, es))
> > -			goto failed_mount2;
> > +	    EXT3_HAS_COMPAT_FEATURE(sb, EXT3_FEATURE_COMPAT_HAS_JOURNAL)) { {
> > +		    mount_cost = 5;
> > +		    if (ext3_load_journal(sb, es))
> > +			    goto failed_mount2;
> > +	    }
> 
> AFAICS, this just means that if you have an ext3 filesystem
> (i.e. has_journal) that you will fsck 5x as often, not so great.  You
> should instead check for INCOMPAT_RECOVER instead of HAS_JOURNAL.

Oops, you are right. Updated patch is attached.

> Instead, you could change this to only increment the mount count after
> a clean unmount 20% of the time (randomly).  Since most people bitch
> about the full fsck anyways this is probably the better choice than
> increasing the frequency of checks and forcing the users to change the
> check interval to get the old behaviour.

Nice hack.... would that be acceptable?
									Pavel

-- 
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!

  reply	other threads:[~2004-07-14 20:37 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-14 13:15 ext3: bump mount count on journal replay Pavel Machek
2004-07-14 19:55 ` Theodore Ts'o
2004-07-14 20:30   ` Pavel Machek
2004-07-14 20:05 ` Andreas Dilger
2004-07-14 20:32   ` Pavel Machek [this message]
2004-07-16 20:41     ` [Ext2-devel] " Andreas Dilger
2004-07-16 21:06       ` Pavel Machek

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=20040714203258.GC25802@elf.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=ext2-devel@lists.sourceforge.net \
    --cc=linux-kernel@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.