tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: choosing the file system block size



> What I'm trying to do is to figure out the optimal block/fragment
> size for a filesystem.  My idea is to take the given data set and,
> for various block/fragment sizes, compute the overhead caused by that
> choice.

This is reasonable, if your only metric for "optimal" is "amount of
overhead space required".  (Which may be true in your case, but it
seems to me to be worth mentioning anyway.)

> Since I'm not interested in the real amount of space required, I can
> ignore super blocks, cylinder group heads and inodes, since the space
> required by them doesn't vary with the choice of block size.

Yes and no.  There are aspects of cylinder groups which do change with
block size, though I haven't though about it enough to figure out
whether the proportion of space dedicated to overhead changes (ie,
whether there are multiple effects which cancel out).  I do know that
when I newfs with different block sizes, I often get different numbers
of CGs and thus different proportions of space dedicated to CG heads.

> Now, what else do I need?  [...freelist...cluster map...]  But what
> do I need for the summary infomation?  What else have I forgotten?

I'm not sure.  I'd suggest reading over the source to newfs and/or
fsck; they know a good deal about that stuff, and are much smaller and
more comprehensible than the filesystem kernel code.

/~\ The ASCII                             Mouse
\ / Ribbon Campaign
 X  Against HTML                mouse%rodents-montreal.org@localhost
/ \ Email!           7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B


Home | Main Index | Thread Index | Old Index