*BSD News Article 63495


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!news.mel.connect.com.au!munnari.OZ.AU!news.ecn.uoknor.edu!news.eng.convex.com!newshost.convex.com!bcm.tmc.edu!cs.utexas.edu!howland.reston.ans.net!gatech!swrinde!sdd.hp.com!hamblin.math.byu.edu!park.uvsc.edu!usenet
From: Terry Lambert <terry@lambert.org>
Newsgroups: comp.unix.bsd.freebsd.misc,comp.os.linux.development.system
Subject: Re: The better (more suitable)Unix?? FreeBSD or Linux
Date: 1 Mar 1996 22:09:11 GMT
Organization: Utah Valley State College, Orem, Utah
Lines: 39
Message-ID: <4h7si7$qoh@park.uvsc.edu>
References: <4er9hp$5ng@orb.direct.ca> <311C5EB4.2F1CF0FB@freebsd.org> <ALBERT.96Feb27155949@krakatoa.ccs.neu.edu>
NNTP-Posting-Host: hecate.artisoft.com
Xref: euryale.cc.adfa.oz.au comp.unix.bsd.freebsd.misc:15418 comp.os.linux.development.system:19315

albert@krakatoa.ccs.neu.edu (Albert Cahalan) wrote:
] Nope, blocks are not deallocated until the metadata is written.
] The filesystem always has a consistant state - all fdisk needs
] to do is check a few CRC protected, timestamped blocks to make
] sure they all agree.  This is so trivial that the kernel can
] do it at mount time.  This ideal filesystem wastes space though.
] 
] How it works:

[ ... ]

You are talking about EXT2FS?  This is a description of ordered
bitmap writes.

This belies the claims of "async".

If the bitmap write is async scheduled, then the allocation can
occur after the scheduling but before the write takes place.

The only way the write can be known to have taken place before
an allocation is allowed is if the bitmap write is synchronous,
or there is an attached completion routine (it is ordered).

In either case, you must know the bitmap is on the disk with
the block deallocated.

Async writes *can* be ordered, of course, but because they are
async, there is no guarantee that they will be, since the
clustering code is always free to reorder them in any way it
sees fit (including writing data blocks out before the blocks
containing the metadata referring to them, or vice versa).


					Regards,
                                        Terry Lambert
                                        terry@cs.weber.edu
---
Any opinions in this posting are my own and not those of my present
or previous employers.