Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 12 Dec 2011 18:09:53 +0000
From:      RW <rwmaillists@googlemail.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: 9.0 install and journaling
Message-ID:  <20111212180953.2bc4af97@gumby.homeunix.com>
In-Reply-To: <4EE442DC.7080107@herveybayaustralia.com.au>
References:  <4EE32BB6.3020105@herveybayaustralia.com.au> <alpine.BSF.2.00.1112100755520.11994@wonkity.com> <4EE38454.3020307@otenet.gr> <4EE3D1F0.60500@herveybayaustralia.com.au> <alpine.BSF.2.00.1112101509220.14596@wonkity.com> <4EE3DA85.4070903@herveybayaustralia.com.au> <20111211002348.56497fde@gumby.homeunix.com> <4EE442DC.7080107@herveybayaustralia.com.au>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 11 Dec 2011 15:42:52 +1000
Da Rock wrote:

> On 12/11/11 10:23, RW wrote:
> > On Sun, 11 Dec 2011 08:17:41 +1000
> > Da Rock wrote:
> >
> >
> >>> SUJ speeds up the check a lot, seconds as opposed to minutes.  If
> >>> something happens to the journal, it falls back to a standard
> >>> fsck.
> >> But fsck needs to be run manually- I have users that can't do that,
> >> and the filesystem corrupts. Ergo gjournal; it boots up and fixes
> >> on the fly. So SU+J needs a manual fsck before booting proper or
> >> can it just boot and be done?
> > It's not very different; gjournal and SU both attempt to leave the
> > filesystem in an coherent state, but both still need a preen to
> > recover lost space. In either case the preen can fail requiring a
> > full fsck.
> >
> > Journalled SU make SU behave more like gjournal in that you can do a
> > fast foreground check which avoids the lengthy background fsck and
> > avoids deferring the handling of unexpected inconsistencies to the
> > next boot.
> >
> Yes, but I don't do a fsck to recover gjournal- it has a miniscule
> blurp for a nanosecond and prints a message at boot and thats it. 



If the filesystem is mounted via fstab the fsck is normally done
automatically. You may not have noticed this because if nothing needs
doing fsck_ufs can mark a gjournal filesystem clean instantaneously.

There are two other possibilities. The first is that it may spend some
time recovering orphaned files; this is much faster that a full fsck
but it's still seconds or minutes. The second is that the journal sync
may have failed in which case fsck terminates with "UNEXPECTED
INCONSISTENCY" which requires a full fsck. This is similar to SU. In
either case you only need a full fsck when things haven't worked out in
line with the theory.


> Is
> it the same with su+j? If it does then I'll drop gjournal (and the
> performance hit) and I'll use su+j when I jump to 9.0.

The  SU equivalent of the journal sync is done before the crash
happens. With SU you can have an instantaneous foreground fsck by
deferring the recovery of lost files until the background check that
runs after bootup. Journalling SU eliminates the few minutes
of sluggish disk IO that that can cause.

I've been disappointed by gjournal, the performance hit isn't as bad as
background fsck but it is substantial and permanent, rather than a few
minutes hare and there. I was hoping that gjournal would be more robust,
but I've seen the occassional "UNEXPECTED INCONSISTENCY" just like I
have with SU.









Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20111212180953.2bc4af97>