Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 12 May 1999 10:57:28 -0400 (EDT)
From:      Zhihui Zhang <zzhang@cs.binghamton.edu>
To:        freebsd-hackers@freebsd.org
Subject:   Metablock caching & negative block #
Message-ID:  <Pine.GSO.3.96.990512104153.8082A-100000@sol.cs.binghamton.edu>

next in thread | raw e-mail | index | archive | help

It seems to me that metablocks such as filesystem superblock and cylinder
group control blocks are associated with the device vnode.  The indirect
blocks are associated with the file using them to find data blocks.  These
indirect blocks are identified by negative block numbers.  This makes the
max file size limited by 2^31 * 2^9, because we need one bit in the block
number to cope with negative block numbers.  The first time I understand
this I think it is cool because it allows buffering both kinds of data in
the same way and we can differentiate them at the same time.

Now my question is why we must associated these (double, triple) indirect
blocks with the file using them?  If these indirect blocks can be handled
like other metablocks (superblocks, cylinder group control blocks), we can
save one bit and make the max file size to be 2^32*2^9. 

By the way, all other metablocks seem to be delay-written. In other words,
they are not written synchronously.  What happens if the system crashes
before their updates go to disk.  I read in the mailinglist that FreeBSD
metadata I/O are conservative.  Can anyone describe this a little bit for
me. 

Any help is appreciated.

--------------------------------------------------
Zhihui Zhang.  Please visit http://www.freebsd.org
--------------------------------------------------



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.GSO.3.96.990512104153.8082A-100000>