From: Phillip Susi <psusi@cfl.rr.com>
To: Andreas Dilger <adilger@dilger.ca>
Cc: linux-ext4@vger.kernel.org
Subject: Re: 64bit filesystem questions
Date: Fri, 10 Jun 2011 17:21:04 -0400 [thread overview]
Message-ID: <4DF28AC0.2010505@cfl.rr.com> (raw)
In-Reply-To: <9500D51F-7E89-41F2-9A77-0E1A79136240@dilger.ca>
On 6/10/2011 4:37 PM, Andreas Dilger wrote:
> I hope it is obvious that a single bitmap block can only address the number
> of bits (==blocks) that fit within that block. To address more blocks the
> block bitmap needs to be larger than a single block in size. One possible
> way to do this (discussed early on for ext4) would be to have N block
> bitmap blocks per group. That raises issues of how to address those blocks
> for each "block group", and what the meaning of a "block group" really is.
I thought it was obvious that if there were more blocks, then you would
have more than one bitmap block and it would just follow the first.
> The other (very similar, but not identical) approach is to essentially merge
> N adjacent "block groups" into a single "large block group" that has N block
> bitmaps, and addresses N * blocksize * 8 blocks per "large block group".
> In this case "N" is the flex_bg factor (constrained to 2^n), and the "large
> block group" is called a "flex group". It achieves exactly the same thing
> as having N block bitmaps per group, with the only difference that there are
> N group descriptors that point to the bitmaps, and they no longer have to be
> located within the groups themselves
The other side effect is that you have N inode tables and N inode
bitmaps. A typical fs these days seems to have 8192 inodes in each bg,
which gives far more inodes than needed, and only uses 1/4 of the inode
bitmap block.
Now that I've looked a bit more at the code, it seems the 32k block
limit comes from the old ext2 block group descriptor only having a 16
bit field for the free blocks count. This was fixed in the ext4 bg
descriptor, but it seems that is not actually used except on a 64bit fs.
It looks like a few more bits of code need cleaned up to allow for
more blocks per group when using 64bit.
> If you treat the four "bbbb" blocks as a single block bitmap, and "iiii"
> as a single inode bitmap, and the contiguous range of free blocks as a
> single group, it is exactly what you are asking for - a larger bitmap.
While each of those inode bitmaps may follow the previous, each one is
typically only 1/4 used and the rest ignored. It would be better to
have only the single inode bitmap for a single, larger bg.
prev parent reply other threads:[~2011-06-10 21:21 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-09 14:36 64bit filesystem questions Phillip Susi
2011-06-10 0:08 ` Andreas Dilger
2011-06-10 15:19 ` Phillip Susi
2011-06-10 16:19 ` Andreas Dilger
2011-06-10 17:14 ` Phillip Susi
2011-06-10 17:29 ` Andreas Dilger
2011-06-10 17:45 ` Phillip Susi
2011-06-10 20:37 ` Andreas Dilger
2011-06-10 21:21 ` Phillip Susi [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4DF28AC0.2010505@cfl.rr.com \
--to=psusi@cfl.rr.com \
--cc=adilger@dilger.ca \
--cc=linux-ext4@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).