gjournal & async

Pawel Jakub Dawidek pjd at FreeBSD.org
Sun Apr 22 16:46:39 UTC 2007


On Sun, Apr 22, 2007 at 06:28:21PM +0200, Ivan Voras wrote:
> Pawel Jakub Dawidek wrote:
> > On Sun, Apr 22, 2007 at 05:48:39PM +0200, Ivan Voras wrote:
> >> Pawel Jakub Dawidek wrote:
> >>> On Sun, Apr 22, 2007 at 02:43:29AM +0200, Ivan Voras wrote:
> >>>> How does gjournal guarantee corectness if UFS is mounted async? AFAIK
> >>>> the "async" handling of IO requests is done by the UFS, the writes are
> >>>> not rescheduled at the GEOM layer?
> >>> GJournal has some minimum knowledge about VFS. Before it does journal
> >>> switch, it synchronize and suspends file system. This way we can be sure
> >>> everything is on disk in a consistent state.
> >> Thanks. So, this (async support) could actually work with other file
> >> systems, like ext2 and msdos?
> > 
> > Once gjournal is taught about them, yes.
> 
> Then you're not interfacing in the VFS layer, you're hooking directly
> into UFS?

GJournal talks to VFS to sync/suspend file system, but it also needs to
have some knowledge about file system to mark it as clean, so fsck won't
complain. Look at sys/geom/journal/g_journal_ufs.c (dirty method is
mostly not used, it is there for consistency and in case journal itself
become broken/corrupted).

-- 
Pawel Jakub Dawidek                       http://www.wheel.pl
pjd at FreeBSD.org                           http://www.FreeBSD.org
FreeBSD committer                         Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-geom/attachments/20070422/68b8cee2/attachment.pgp


More information about the freebsd-geom mailing list