login
Header Space

 
 

Re: [PATCH] Clustering indirect blocks in Ext3

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Andrew Morton <akpm@...>
Cc: Andreas Dilger <adilger@...>, <linux-kernel@...>, Ken Chen <kenchen@...>, Mike Waychison <mikew@...>
Date: Friday, November 16, 2007 - 6:27 pm

On Nov 15, 2007 11:02 PM, Andrew Morton <akpm@linux-foundation.org> wrote:

There are couple of factors to consider when choosing a size:
1. The size cannot be too small, or the metacluster will fill up too
quickly and then we'll have to fall back to regular indirect block
allocation. E.g., if average file size of files in a block group is
512KB, a default block group having 32K blocks of size 4KB will need
~256 indirect blocks, one for each file.
2. If number of indirect blocks is too high, there will be less space
for data block allocation and so it'll make it more likely that we run
out of data blocks and start using blocks from the metacluster which
makes metaclustering useless.

Considering these factors, I think we should have <1% of blocks
reserved for the metacluster. The current patch uses (blocks_per_group
/ 128).


Metaclustering is honored only as long as we have free data blocks and
free metacluster blocks. If we run out of either, we start using the
other. Of course, once that happens indirect blocks may not be
clustered anymore.


No because of above reason.


It is actually much simpler than the reservation code, so I haven't
used it. The logic is implemented in <20 lines in
ext3_try_to_allocate().


OK, I'll investigate this further.


kernbench below shows the behavior with small files. I'll also post
results from running
compilebench.


Not necessarily. If a lot of files use indirect blocks which happens when file
length >48KB on a 4KB blocksize file system, then we have a lot of
indirect blocks to read during fsck and hence this patch will be useful. But
if most files are <= 48KB, then the speedup is less/none of course.


I'll post results of running compilebench shortly.

-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] Clustering indirect blocks in Ext3, Abhishek Rai, (Fri Nov 16, 1:02 am)
Re: [PATCH] Clustering indirect blocks in Ext3, Andrew Morton, (Fri Nov 16, 3:02 am)
Re: [PATCH] Clustering indirect blocks in Ext3, Abhishek Rai, (Fri Nov 16, 6:27 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Theodore Tso, (Fri Nov 16, 5:11 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Abhishek Rai, (Fri Nov 16, 8:25 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Theodore Tso, (Fri Nov 16, 10:58 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Abhishek Rai, (Fri Dec 21, 10:15 am)
Re: [PATCH] Clustering indirect blocks in Ext3, Abhishek Rai, (Thu Jan 10, 5:17 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Daniel Phillips, (Fri Jan 11, 1:05 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Andrew Morton, (Fri Jan 11, 8:04 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Daniel Phillips, (Sat Jan 12, 2:05 am)
Re: [PATCH] Clustering indirect blocks in Ext3, Abhishek Rai, (Sun Jan 13, 1:06 am)
Re: [PATCH] Clustering indirect blocks in Ext3, Abhishek Rai, (Sat Nov 17, 4:58 am)
Re: [PATCH] Clustering indirect blocks in Ext3, Andreas Dilger, (Fri Nov 16, 7:28 am)
Re: [PATCH] Clustering indirect blocks in Ext3, Matt Mackall, (Fri Nov 16, 3:37 am)
Re: [PATCH] Clustering indirect blocks in Ext3, Abhishek Rai, (Sun Nov 18, 11:52 am)
Re: [PATCH] Clustering indirect blocks in Ext3, John Stoffel, (Tue Nov 20, 4:25 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Matt Mackall, (Sun Nov 18, 4:47 pm)
Re: [PATCH] Clustering indirect blocks in Ext3, Kyungmin Park, (Mon Nov 19, 6:34 am)
speck-geostationary