Updated ext4/jbd2 patches based on 2.6.19-rc1
Subsystems (2)
I have rebuilt the ext4/jbd2 patches against linux-2.6.19-rc1. The
patch set is located at ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches-2.6.19-rc1.tar.gz
Broken out patches in ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches
The patches begin with exact copies of the rc1 version of ext3 and jbd, so there are no ext3/jbd patches currently in mainline that need to be applied to the new code. I'll continue to watch ext3/jbd for patches that need to be ported to ext4/jbd2.
Signature · 2 lines
David Kleikamp IBM Linux Technology Center
Quoted 11 lines · On Thu, 05 Oct 2006 13:23:30 -0500 Dave Kleikamp <[email protected]> wrote:
I have rebuilt the ext4/jbd2 patches against linux-2.6.19-rc1. The
patch set is located at ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches-2.6.19-rc1.tar.gzBroken out patches in ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches
The patches begin with exact copies of the rc1 version of ext3 and jbd, so there are no ext3/jbd patches currently in mainline that need to be applied to the new code. I'll continue to watch ext3/jbd for patches that need to be ported to ext4/jbd2.
OK...
Linus, what's the best way of doing this? Will git dtrt with a patch which copies files, or would a script which does the mkdir's and cp's be better?
Quoted 3 lines · Andrew Morton
Linus, what's the best way of doing this? Will git dtrt with a patch which copies files, or would a script which does the mkdir's and cp's be better?
Git should dtrt.
In fact, if you use
git diff -C
it should generate the appropriate "file copied" things automatically, and you don't need any huge file at all, you'll get a "patch" that looks something like
diff --git a/fs/ext3/inode.c b/fs/ext4/inode.c similarity index 100%
copy from fs/ext3/inode.c
copy to fs/ext4/inode.c
diff --git a/fs/ext3/super.c b/fs/ext4/super.c similarity index 98%
copy from fs/ext3/super.c
copy to fs/ext4/super.c
index xyz..zzy 100644
--- a/fs/ext3/super.c
+++ b/fs/ext4/super.c
.. small diff that changes "ext3" to "ext4" goes here ..
ie you'll effectively get the best of both worlds: a "diff", but one that is actually readable and shows what is going on.
I hate to beat my own drum (not really), but git really _is_ a lot better than anything else out there ;)
Linus
Quoted 30 lines · Linus Torvalds
Quoted 3 lines · Andrew Morton
Linus, what's the best way of doing this? Will git dtrt with a patch which copies files, or would a script which does the mkdir's and cp's be better?
Git should dtrt.
In fact, if you use
git diff -C
it should generate the appropriate "file copied" things automatically, and you don't need any huge file at all, you'll get a "patch" that looks something like
diff --git
a/fs/ext3/inode.cb/fs/ext4/inode.csimilarity index 100%
copy fromfs/ext3/inode.c
copy tofs/ext4/inode.c
diff --gita/fs/ext3/super.cb/fs/ext4/super.csimilarity index 98%
copy fromfs/ext3/super.c
copy tofs/ext4/super.c
index xyz..zzy 100644
---a/fs/ext3/super.c
+++b/fs/ext4/super.c
.. small diff that changes "ext3" to "ext4" goes here ..
Quoted 2 lines
ie you'll effectively get the best of both worlds: a "diff", but one that is actually readable and shows what is going on.
We haven't been using git to manage ext4 so far, although in hindsight it probably would have made things easier. I'm assuming that you're just suggesting this for educational purposes and that git will handle the patches that Andrew picked up into -mm just fine.
I could re-generate the patches that do the copies from git, but I don't believe it will be that beneficial at this point.
Quoted 2 lines
I hate to beat my own drum (not really), but git really _is_ a lot better than anything else out there ;)
No argument here :-)
Shaggy
Signature · 2 lines
David Kleikamp IBM Linux Technology Center
Quoted 6 lines · Dave Kleikamp
On Thu, 2006-10-05 at 16:25 -0700, Linus Torvalds wrote:
We haven't been using git to manage ext4 so far, although in hindsight it probably would have made things easier. I'm assuming that you're just suggesting this for educational purposes and that git will handle the patches that Andrew picked up into -mm just fine.
Well, also that even if you're not using git, what any random person can do is to actually just import the current state into git, and do the simple "git diff -C" thing to get the nicer diff.
One of the advantages about git is that "intent" doesn't matter. Git only tracks cold, hard data. So if you copied a file, git doesn't care one whit whether you _tell_ it that you copied it or not: it will purely look at the end result, and say "you copied it" if the file looks the same.
Quoted 2 lines
I could re-generate the patches that do the copies from git, but I don't believe it will be that beneficial at this point.
The only advantage (but I'd argue that it's a real one, and very possibly worth it) is that when this gets sent to me (or anybody else) by email, it can be sent in a format that is actually readable, instead of sending it as a huge patch that doesn't actually talk about what it does..
Linus
Quoted 11 lines · On Thu, 05 Oct 2006 13:23:30 -0500 Dave Kleikamp <[email protected]> wrote:
I have rebuilt the ext4/jbd2 patches against linux-2.6.19-rc1. The
patch set is located at ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches-2.6.19-rc1.tar.gzBroken out patches in ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches
The patches begin with exact copies of the rc1 version of ext3 and jbd, so there are no ext3/jbd patches currently in mainline that need to be applied to the new code. I'll continue to watch ext3/jbd for patches that need to be ported to ext4/jbd2.
The only patch I can see at present in -mm and all the git trees is fs-cache-provide-a-filesystem-specific-syncable-page-bit.patch, which touches ext3. It renames PageChecked to PageFsMisc and so it'll break the build nicely.
I'll try to remember to cc this list on jbd and ext3-affecting patches.
Quoted 11 lines · On Thu, 05 Oct 2006 13:23:30 -0500 Dave Kleikamp <[email protected]> wrote:
I have rebuilt the ext4/jbd2 patches against linux-2.6.19-rc1. The
patch set is located at ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches-2.6.19-rc1.tar.gzBroken out patches in ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches
The patches begin with exact copies of the rc1 version of ext3 and jbd, so there are no ext3/jbd patches currently in mainline that need to be applied to the new code. I'll continue to watch ext3/jbd for patches that need to be ported to ext4/jbd2.
Could we please have a few nice words about ext4 for the record? Like, what its features are, how one creates an instance, where to get the correct userspace tools from, stability level, any known shortcomings, issues, etc?
Thanks.
Quoted 4 lines · On Thu, 5 Oct 2006 17:39:33 -0700 Andrew Morton <[email protected]> wrote:
Could we please have a few nice words about ext4 for the record? Like, what its features are, how one creates an instance, where to get the correct userspace tools from, stability level, any known shortcomings, issues, etc?
So I guess I get to write this.
Quoted 9 lines · Andrew Morton
Quoted 4 lines · On Thu, 5 Oct 2006 17:39:33 -0700 Andrew Morton <[email protected]> wrote:
Could we please have a few nice words about ext4 for the record? Like, what its features are, how one creates an instance, where to get the correct userspace tools from, stability level, any known shortcomings, issues, etc?
So I guess I get to write this.
Hopefully not :)
We should be able to put something together for a start. Where should this reside ? Under Documentation/filesystems/ext4.txt ?
However, since this is still very clearly a "development" branch at the moment, with lots of ongoing work both on the kernel and even more so on the tools side, how much detail are you looking for ?
Regards
Suparna
Quoted 4 lines
-
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 3 lines
Suparna Bhattacharya ([email protected]) Linux Technology Center IBM Software Lab, India
Quoted 9 lines · On Tue, 10 Oct 2006 13:24:02 +0530 Suparna Bhattacharya <[email protected]>…
Quoted 8 lines · Andrew Morton
Quoted 4 lines · On Thu, 5 Oct 2006 17:39:33 -0700 Andrew Morton <[email protected]> wrote:
Could we please have a few nice words about ext4 for the record? Like, what its features are, how one creates an instance, where to get the correct userspace tools from, stability level, any known shortcomings, issues, etc?
Quoted 5 lines
Quoted 1 line
So I guess I get to write this.
Hopefully not :)
We should be able to put something together for a start. Where should this reside ? UnderDocumentation/filesystems/ext4.txt?
That sounds appropriate. And in the patch changelog.
Quoted 3 lines
However, since this is still very clearly a "development" branch at the moment, with lots of ongoing work both on the kernel and even more so on the tools side, how much detail are you looking for ?
We should make it as easy as possible for our testers to get up and running and using all available features. They're skilled, so a simple user guide which tells them what the features are and how to access them should suffice, thanks.
RFC PATCH 1/1 Documentation/filesystems/ext4.txt
Quoted 7 lines · Andrew Morton
Quoted 4 lines · On Tue, 10 Oct 2006 13:24:02 +0530 Suparna Bhattacharya <[email protected]>…
Quoted 3 lines · Andrew Morton
On Thu, 5 Oct 2006 17:39:33 -0700
Andrew Morton <[email protected]> wrote:
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 4 lines
Could we please have a few nice words about ext4 for the record? Like, what its features are, how one creates an instance, where to get the correct userspace tools from, stability level, any known shortcomings, issues, etc?
So I guess I get to write this.
Sorry I didn't get something written sooner. This is based off of what you put in the -mm1 announcement.
Quoted 3 lines
Quoted 3 lines
Hopefully not :)
We should be able to put something together for a start. Where should this reside ? UnderDocumentation/filesystems/ext4.txt?
Suparna put this together and I updated it a bit.
Quoted 1 line
That sounds appropriate. And in the patch changelog.
How do you want to handle the patch set? I could resend it with more comments, put it into git, or do you just want to plug the comments into the patches you are carrying? I can do whatever works best for you.
Quoted 8 lines
Quoted 3 lines
However, since this is still very clearly a "development" branch at the moment, with lots of ongoing work both on the kernel and even more so on the tools side, how much detail are you looking for ?
We should make it as easy as possible for our testers to get up and running and using all available features. They're skilled, so a simple user guide which tells them what the features are and how to access them should suffice, thanks.
This file, ext4.txt, was put together with information from Andrew Morton, Andreas Dilger, Suparna Bhattacharya, and Ted Ts'o.
I copied the mount options, with the exception of "extents", from ext3.txt, so if anyone is aware of anything out-of-date, please let me know.
Documentation/filesystems/00-INDEX +2 -0
@@ -34,6 +34,8 @@ ext2.txt - info, mount options and specifications for the Ext2 filesystem. ext3.txt - info, mount options and specifications for the Ext3 filesystem. +ext4.txt + - info, mount options and specifications for the Ext4 filesystem. files.txt - info on file management in the Linux kernel. fuse.txt
Documentation/filesystems/ext4.txt +236 -0
236 lines not on this page · raw message
Signature · 2 lines
David Kleikamp IBM Linux Technology Center
Re: [RFC] [PATCH] Documentation/filesystems/ext4.txt
Quoted 5 lines · On Tue, 10 Oct 2006 15:02:35 -0500 Dave Kleikamp <[email protected]> wrote:
Quoted 3 lines
Quoted 3 lines
Hopefully not :)
We should be able to put something together for a start. Where should this reside ? UnderDocumentation/filesystems/ext4.txt?Suparna put this together and I updated it a bit.
Great, thanks.
Quoted 5 lines
Quoted 1 line
That sounds appropriate. And in the patch changelog.
How do you want to handle the patch set? I could resend it with more comments, put it into git, or do you just want to plug the comments into the patches you are carrying? I can do whatever works best for you.
I'll just send what I have now in the next batch, probably this evening.
Documentation/filesystems/ext4.txt line 19
Quoted 4 lines
Documentation/filesystems/ext4.txt +4
-0+ - Grab updated e2fsprogs from + ftp://ftp.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs-interim/ + This is a patchset on top of e2fsprogs-1.39, which can be found at + ftp://ftp.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs/
Could we please get a patched tarball up there? The easier we make it for our testers, the more we get.
Re: [RFC] [PATCH] Documentation/filesystems/ext4.txt
In reply to Dave KleikampQuoted 1 line · Dave Kleikamp
+ - It's still mke2fs -j
/dev/hda1
I would suggest "mke2fs -j -O dir_index -I 256 /dev/XXX" to be more representative of what will be used in the future.
Documentation/filesystems/ext4.txt line 233
Quoted 2 lines
Documentation/filesystems/ext4.txt +2
-0+programs: http://e2fsprogs.sourceforge.net/ + http://ext2resize.sourceforge.net
You should likely remove ext2resize from this list, it hasn't got any support for extent-mapped files.
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.
Re: [RFC] [PATCH] Documentation/filesystems/ext4.txt
In reply to Dave KleikampDocumentation/filesystems/ext4.txt line 69
Quoted 13 lines · Dave Kleikamp
+2.2 Candidate features for future inclusion
Documentation/filesystems/ext4.txt +12
-0+ +There are several under discussion, whether they all make it in is +partly a function of how much time everyone has to work on them: + +* improved file allocation (multi-block alloc, delayed alloc; basically done) +* fix 32000 subdirectory limit (patch exists, needs some e2fsck work) +* nsec timestamps for mtime, atime, ctime, create time (patch exists, + needs some e2fsck work) +* inode version field on disk (NFSv4, Lustre; prototype exists) +* reduced mke2fs/e2fsck time via uninitialized groups (prototype exists) +* journal checksumming for robustness, performance (prototype exists) +* persistent file preallocation (e.g for streaming media, databases)
Could you add "support of larger block group size" ? Currently, a prototype exists, but we still have tests to do.
Thanks,
Valérie
-
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 4 lines · On Thu, 05 Oct 2006 13:23:30 -0500 Dave Kleikamp <[email protected]> wrote:
I have rebuilt the ext4/jbd2 patches against linux-2.6.19-rc1. The
patch set is located at ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches-2.6.19-rc1.tar.gz
So let me see if I have this right.
You grab Alexandre's kit from http://www.bullopensource.org/ext4/20060926/
and a plain old `mke2fs -j' gives a filesystem which will mount as ext3 or ext4.
If you then mount this filesystem with `-t ext4dev -o extents', it becomes incompatible with the ext3 driver. Yes?
What else aren't we being told? ;)
Quoted 6 lines · On Thu, 5 Oct 2006 20:55:26 -0700 Andrew Morton <[email protected]> wrote:
You grab Alexandre's kit from http://www.bullopensource.org/ext4/20060926/
and a plain old `mke2fs -j' gives a filesystem which will mount as ext3 or ext4.If you then mount this filesystem with `-t ext4dev -o extents', it becomes incompatible with the ext3 driver. Yes?
`mke2fs -O extents' doesn't work. Should it?
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Andrew Morton (AM) writes:
AM> On Thu, 5 Oct 2006 20:55:26 -0700
Quoted 6 lines · AM> Andrew Morton <[email protected]> wrote:
Quoted 6 lines
You grab Alexandre's kit from http://www.bullopensource.org/ext4/20060926/
and a plain old `mke2fs -j' gives a filesystem which will mount as ext3 or ext4.If you then mount this filesystem with `-t ext4dev -o extents', it becomes incompatible with the ext3 driver. Yes?
AM> `mke2fs -O extents' doesn't work. Should it?
I believe we keep extents as a mount option for a while, just for development purposes. though there is an agreement about mke2fs -O extents, IIRC.
thanks, Alex
Quoted 8 lines · On Thu, 5 Oct 2006 20:55:26 -0700 Andrew Morton wrote:
Quoted 4 lines · On Thu, 05 Oct 2006 13:23:30 -0500 Dave Kleikamp <[email protected]> wrote:
I have rebuilt the ext4/jbd2 patches against linux-2.6.19-rc1. The
patch set is located at ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches-2.6.19-rc1.tar.gz
Quoted 8 lines
So let me see if I have this right.
You grab Alexandre's kit from http://www.bullopensource.org/ext4/20060926/
and a plain old `mke2fs -j' gives a filesystem which will mount as ext3 or ext4.If you then mount this filesystem with `-t ext4dev -o extents', it becomes incompatible with the ext3 driver. Yes?
I thought we s/ext4dev/ext4/ ??
Quoted 1 line
What else aren't we being told? ;)
---
~Randy
Quoted 1 line · On Thu, 5 Oct 2006 21:54:42 -0700 Randy Dunlap <[email protected]> wrote:
I thought we s/ext4dev/ext4/ ??
nope.
Quoted 5 lines · Randy Dunlap
Quoted 2 lines · On Thu, 5 Oct 2006 20:55:26 -0700 Andrew Morton wrote:
If you then mount this filesystem with `-t ext4dev -o extents', it becomes incompatible with the ext3 driver. Yes?
I thought we s/ext4dev/ext4/ ??
No, we want to leave it at ext4dev for a while, to make it very clear that this is still under development. We want to get the existing patches upstream so they don't become completely unwieldy, and earlier testing is also good, but it is not yet feature complete.
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.
Quoted 5 lines · On Thu, 5 Oct 2006 23:53:05 -0600 Andreas Dilger <[email protected]> wrote:
Quoted 4 lines · Randy Dunlap
Quoted 2 lines · On Thu, 5 Oct 2006 20:55:26 -0700 Andrew Morton wrote:
If you then mount this filesystem with `-t ext4dev -o extents', it becomes incompatible with the ext3 driver. Yes?
Quoted 7 lines
Quoted 1 line
I thought we s/ext4dev/ext4/ ??
No, we want to leave it at ext4dev for a while, to make it very clear that this is still under development. We want to get the existing patches upstream so they don't become completely unwieldy, and earlier testing is also good, but it is not yet feature complete.
What features are missing?
Heck, what features does it have now? Guys, we cannot release this thing to the public without telling them what it is, how to use it, where to get the tools from and what the roadmap is.
Quoted 9 lines · Andrew Morton
Quoted 5 lines · On Thu, 5 Oct 2006 23:53:05 -0600 Andreas Dilger <[email protected]> wrote:
No, we want to leave it at ext4dev for a while, to make it very clear that this is still under development. We want to get the existing patches upstream so they don't become completely unwieldy, and earlier testing is also good, but it is not yet feature complete.
What features are missing?
There are several under discussion, whether they all make it in is partly a function of how much time everyone has to work on them:
- improved file allocation (multi-block alloc, delayed alloc; basically done)
- fix 32000 subdirectory limit (patch exists, needs some e2fsck work)
- nsec timestamps for mtime, atime, ctime, create time (patch exists, needs some e2fsck work)
- inode version field on disk (NFSv4, Lustre; prototype exists)
- reduced mke2fs/e2fsck time via uninitialized groups (prototype exists)
- journal checksumming for robustness, performance (prototype exists)
Features like metadata checksumming have been discussed and planned for a bit but no patches exist yet so I'm not sure they're in the near-term roadmap.
Quoted 3 lines
Heck, what features does it have now? Guys, we cannot release this thing to the public without telling them what it is, how to use it, where to get the tools from and what the roadmap is.
Features now:
- ability to use filesystems > 16TB
- extent format reduces metadata overhead (RAM, IO for access, transactions)
- extent format more robust in face of on-disk corruption due to magics, internal redunancy in tree
Features soon (previously available, to be enabled by default by "mkefs.ext4"):
- dir_index and resize inode will be on by default
- large inodes will be used by default for fast EAs, nsec timestamps, etc
Other features as above patches are committed.
The big performance win will come with mballoc and delalloc. CFS has been using mballoc for a few years already with Lustre, and IBM + Bull did a lot of benchmarking on it. The reason it isn't in the first set of patches is partly a manageability issue, and partly because it doesn't directly affect the on-disk format (outside of much better allocation) so it isn't critical to get into the first round of changes. I believe Alex is working on a new set of patches right now.
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.
Quoted 21 lines · Andreas Dilger
Quoted 9 lines · Andrew Morton
Quoted 5 lines · On Thu, 5 Oct 2006 23:53:05 -0600 Andreas Dilger <[email protected]> wrote:
No, we want to leave it at ext4dev for a while, to make it very clear that this is still under development. We want to get the existing patches upstream so they don't become completely unwieldy, and earlier testing is also good, but it is not yet feature complete.
What features are missing?
There are several under discussion, whether they all make it in is partly a function of how much time everyone has to work on them:
- improved file allocation (multi-block alloc, delayed alloc; basically done)
- fix 32000 subdirectory limit (patch exists, needs some e2fsck work)
- nsec timestamps for mtime, atime, ctime, create time (patch exists, needs some e2fsck work)
- inode version field on disk (NFSv4, Lustre; prototype exists)
- reduced mke2fs/e2fsck time via uninitialized groups (prototype exists)
- journal checksumming for robustness, performance (prototype exists)
Quoted 3 lines
Features like metadata checksumming have been discussed and planned for a bit but no patches exist yet so I'm not sure they're in the near-term roadmap.
I would add persistent preallocation (of uninitialized blocks) support to the list. Right now we have only put in support to recognize uninitialized extents so that we can add preallocation, but will be working on developing the actual implementation for persistent preallocation.
Regards
Suparna
Quoted 35 lines
Quoted 4 lines
Heck, what features does it have now? Guys, we cannot release this thing to the public without telling them what it is, how to use it, where to get the tools from and what the roadmap is.
Features now:
- ability to use filesystems > 16TB
- extent format reduces metadata overhead (RAM, IO for access, transactions)
- extent format more robust in face of on-disk corruption due to magics, internal redunancy in treeFeatures soon (previously available, to be enabled by default by "mkefs.ext4"):
-dir_indexand resize inode will be on by default
- large inodes will be used by default for fast EAs, nsec timestamps, etcOther features as above patches are committed.
The big performance win will come with mballoc and delalloc. CFS has been using mballoc for a few years already with Lustre, and IBM + Bull did a lot of benchmarking on it. The reason it isn't in the first set of patches is partly a manageability issue, and partly because it doesn't directly affect the on-disk format (outside of much better allocation) so it isn't critical to get into the first round of changes. I believe Alex is working on a new set of patches right now.
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.-
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 3 lines
Suparna Bhattacharya ([email protected]) Linux Technology Center IBM Software Lab, India
Quoted 7 lines · On Fri, 6 Oct 2006 00:41:03 -0600 Andreas Dilger <[email protected]> wrote:
The big performance win will come with mballoc and delalloc. CFS has been using mballoc for a few years already with Lustre, and IBM + Bull did a lot of benchmarking on it. The reason it isn't in the first set of patches is partly a manageability issue, and partly because it doesn't directly affect the on-disk format (outside of much better allocation) so it isn't critical to get into the first round of changes. I believe Alex is working on a new set of patches right now.
Are you sure that these things will improve allocation much? Reservations made a big improvement there.
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Andrew Morton (AM) writes:
AM> On Fri, 6 Oct 2006 00:41:03 -0600
Quoted 7 lines · AM> Andreas Dilger <[email protected]> wrote:
Quoted 7 lines
The big performance win will come with mballoc and delalloc. CFS has been using mballoc for a few years already with Lustre, and IBM + Bull did a lot of benchmarking on it. The reason it isn't in the first set of patches is partly a manageability issue, and partly because it doesn't directly affect the on-disk format (outside of much better allocation) so it isn't critical to get into the first round of changes. I believe Alex is working on a new set of patches right now.
AM> Are you sure that these things will improve allocation much? Reservations AM> made a big improvement there.
it depends on underlaying storage and workload. mballoc uses buddy internally. it's much simpler and cheaper to find free 2^N blocks compared to bitmap. this is especially important for arrays like DDN and raid5/6 because they require stripe-aligned/-sized requests for good throughput. also, last mballoc takes logical block into account and can preallocate few chunks at different logical offsets for a file. imagine torrent downloading different pieces from few peers.
thanks, Alex
Quoted 13 lines · On Fri, 06 Oct 2006 14:31:59 +0400 Alex Tomas <[email protected]> wrote:
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Andrew Morton (AM) writes:
AM> On Fri, 6 Oct 2006 00:41:03 -0600
Quoted 7 lines · AM> Andreas Dilger <[email protected]> wrote:
Quoted 7 lines
The big performance win will come with mballoc and delalloc. CFS has been using mballoc for a few years already with Lustre, and IBM + Bull did a lot of benchmarking on it. The reason it isn't in the first set of patches is partly a manageability issue, and partly because it doesn't directly affect the on-disk format (outside of much better allocation) so it isn't critical to get into the first round of changes. I believe Alex is working on a new set of patches right now.
Quoted 6 lines
AM> Are you sure that these things will improve allocation much? Reservations AM> made a big improvement there.
it depends on underlaying storage and workload. mballoc uses buddy internally. it's much simpler and cheaper to find free 2^N blocks compared to bitmap.
So mballoc's application is to save CPU cycles?
Quoted 3 lines
this is especially important for arrays like
DDN and raid5/6 because they require stripe-aligned/-sized requests for good throughput.
Does this not imply that there needs to be new linkage between the filesystem and the lower layers? So that raid/etc can inform the filesystem driver about its alignment and striping requirements?
Quoted 3 lines
also, last mballoc takes logical block into
account and can preallocate few chunks at different logical offsets for a file. imagine torrent downloading different pieces from few peers.
hm. You don't need anything as exotic as bittorrent to show up problems in that area:
box:/usr/src/25> sudo bmap vmlinux | wc -l
1152
Hi
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Alex Tomas (AT) writes:
it depends on underlaying storage and workload. mballoc uses buddy internally. it's much simpler and cheaper to find free 2^N blocks compared to bitmap.
AM> So mballoc's application is to save CPU cycles?
AFAIU, we don't implement complex scanning for given size in balloc.c because bitmap isn't very comfortable structure for this and that would require many cycles. with mballoc it becomes possible. for example, to find 1MB free chunk one has to choose group (mballoc tracks number of free chunks in every buddy) and then scan just few bits). thus we can produce better layout and improve performance.
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
this is especially important for arrays like
DDN and raid5/6 because they require stripe-aligned/-sized requests for good throughput.
AM> Does this not imply that there needs to be new linkage between the AM> filesystem and the lower layers? So that raid/etc can inform the AM> filesystem driver about its alignment and striping requirements?
currently, we pass preferred I/O size with mount option (stripe=N). I'd like that sort of communication between block driver and fs. something like f_bsize.
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
also, last mballoc takes logical block into
account and can preallocate few chunks at different logical offsets for a file. imagine torrent downloading different pieces from few peers.
AM> hm. You don't need anything as exotic as bittorrent to show up problems in AM> that area:
AM> box:/usr/src/25> sudo bmap vmlinux | wc -l
AM> 1152
well, this can be (and will be, I very hope :) solved by delayed allocation. I mentioned torrent because it's often used to get really large files. so large that they don't fit cache and delayed allocation won't help much. preallocation can help, but then few preallocations per file is required.
thanks, Alex
Theodore Tso
maintainerQuoted 8 lines · Andrew Morton
Quoted 4 lines · On Thu, 05 Oct 2006 13:23:30 -0500 Dave Kleikamp <[email protected]> wrote:
I have rebuilt the ext4/jbd2 patches against linux-2.6.19-rc1. The
patch set is located at ftp://kernel.org/pub/linux/kernel/people/shaggy/ext4/2.6.19-rc1/ext4-patches-2.6.19-rc1.tar.gz
Quoted 8 lines
So let me see if I have this right.
You grab Alexandre's kit from http://www.bullopensource.org/ext4/20060926/
and a plain old `mke2fs -j' gives a filesystem which will mount as ext3 or ext4.If you then mount this filesystem with `-t ext4dev -o extents', it becomes incompatible with the ext3 driver. Yes?
I agree that's the wrong behaviour, and I've always hated the idea of using using mount -o options to enable ext3/4 features. (When do it with EA's and acl's, sigh, and that's wrong too, but at least I was able to paper over that later by adding default mount option support into the superblock.)
The right way to do this is to only enable a feature like extents after using tune2fs -O extents, or creating a filesystem with mke2fs -O extents.
Can we change the patches to do this, please?
- Ted
PATCH 1/1 Get rid of extents mount option
Quoted 16 lines · Theodore Tso
Quoted 8 lines · Andrew Morton
So let me see if I have this right.
You grab Alexandre's kit from http://www.bullopensource.org/ext4/20060926/
and a plain old `mke2fs -j' gives a filesystem which will mount as ext3 or ext4.If you then mount this filesystem with `-t ext4dev -o extents', it becomes incompatible with the ext3 driver. Yes?
I agree that's the wrong behaviour, and I've always hated the idea of using using mount -o options to enable ext3/4 features. (When do it with EA's and acl's, sigh, and that's wrong too, but at least I was able to paper over that later by adding default mount option support into the superblock.)
Quoted 5 lines
The right way to do this is to only enable a feature like extents after using tune2fs -O extents, or creating a filesystem with mke2fs -O extents.
Can we change the patches to do this, please?
Something like this?
EXT4: Get rid of extents mount option
Enabling an ext4 file system to use extents should be done with 'tune2fs -O extents' or 'mke2fs -O extents', not with a mount option
fs/ext4/extents.c +2 -2
@@ -1875,7 +1875,7 @@ void ext4_ext_init(struct super_block *s* possible initialization would be here */ -if (test_opt (sb,EXTENTS )) { +if (EXT4_HAS_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS )) {printk ("EXT4-fs: file extents enabled" );#ifdef AGRESSIVE_TEST printk (", agressive tests" );
@@ -1900,7 +1900,7 @@ void ext4_ext_init(struct super_block *s*/ void ext4_ext_release (struct super_block *sb) { -if (!test_opt (sb,EXTENTS )) +if (!EXT4_HAS_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS ))return ;#ifdef EXTENTS_STATS
fs/ext4/ialloc.c +1 -8
@@ -618,16 +618,9 @@ got:ext4_std_error (sb, err); goto fail_free_drop; } -if (test_opt (sb,EXTENTS )) { +if (EXT4_HAS_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS )) {EXT4_I (inode)->i_flags |=EXT4_EXTENTS_FL ;ext4_ext_tree_init (handle, inode); -if (!EXT4_HAS_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS )) { - err =ext4_journal_get_write_access (handle,EXT4_SB (sb)->s_sbh); -if (err) goto fail; -EXT4_SET_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS ); -BUFFER_TRACE (EXT4_SB (sb)->s_sbh,"call ext4_journal_dirty_metadata" ); - err =ext4_journal_dirty_metadata (handle,EXT4_SB (sb)->s_sbh); - } }ext4_debug ("allocating inode %lu\n" , inode->i_ino);
fs/ext4/super.c +1 -5
@@ -728,7 +728,7 @@ enum { Opt_usrjquota, Opt_grpjquota, Opt_offusrjquota, Opt_offgrpjquota, Opt_jqfmt_vfsold, Opt_jqfmt_vfsv0, Opt_quota, Opt_noquota, Opt_ignore, Opt_barrier, Opt_err, Opt_resize, Opt_usrquota, - Opt_grpquota, Opt_extents, + Opt_grpquota, }; static match_table_t tokens = {
@@ -778,7 +778,6 @@ static match_table_t tokens = { {Opt_quota, "quota"}, {Opt_usrquota, "usrquota"}, {Opt_barrier, "barrier=%u"}, - {Opt_extents, "extents"}, {Opt_err, NULL}, {Opt_resize, "resize"}, };
@@ -1111,9 +1110,6 @@ clear_qf_name:case Opt_bh:clear_opt (sbi->s_mount_opt,NOBH );break ; -case Opt_extents: -set_opt (sbi->s_mount_opt,EXTENTS ); -break ;default :printk (KERN_ERR "EXT4-fs: Unrecognized mount option \"%s\" "
Shaggy
Signature · 2 lines
David Kleikamp IBM Linux Technology Center
PATCH 1/1 Get rid of extents mount option - try 2
I rushed that out too quick. This one cleans up the header files too.
EXT4: Get rid of extents mount option
Enabling an ext4 file system to use extents should be done with 'tune2fs -O extents' or 'mke2fs -O extents', not with a mount option
fs/ext4/extents.c +2 -2
@@ -1875,7 +1875,7 @@ void ext4_ext_init(struct super_block *s* possible initialization would be here */ -if (test_opt (sb,EXTENTS )) { +if (EXT4_HAS_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS )) {printk ("EXT4-fs: file extents enabled" );#ifdef AGRESSIVE_TEST printk (", agressive tests" );
@@ -1900,7 +1900,7 @@ void ext4_ext_init(struct super_block *s*/ void ext4_ext_release (struct super_block *sb) { -if (!test_opt (sb,EXTENTS )) +if (!EXT4_HAS_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS ))return ;#ifdef EXTENTS_STATS
fs/ext4/ialloc.c +1 -8
@@ -618,16 +618,9 @@ got:ext4_std_error (sb, err); goto fail_free_drop; } -if (test_opt (sb,EXTENTS )) { +if (EXT4_HAS_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS )) {EXT4_I (inode)->i_flags |=EXT4_EXTENTS_FL ;ext4_ext_tree_init (handle, inode); -if (!EXT4_HAS_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS )) { - err =ext4_journal_get_write_access (handle,EXT4_SB (sb)->s_sbh); -if (err) goto fail; -EXT4_SET_INCOMPAT_FEATURE (sb,EXT4_FEATURE_INCOMPAT_EXTENTS ); -BUFFER_TRACE (EXT4_SB (sb)->s_sbh,"call ext4_journal_dirty_metadata" ); - err =ext4_journal_dirty_metadata (handle,EXT4_SB (sb)->s_sbh); - } }ext4_debug ("allocating inode %lu\n" , inode->i_ino);
fs/ext4/super.c +1 -5
@@ -728,7 +728,7 @@ enum { Opt_usrjquota, Opt_grpjquota, Opt_offusrjquota, Opt_offgrpjquota, Opt_jqfmt_vfsold, Opt_jqfmt_vfsv0, Opt_quota, Opt_noquota, Opt_ignore, Opt_barrier, Opt_err, Opt_resize, Opt_usrquota, - Opt_grpquota, Opt_extents, + Opt_grpquota, }; static match_table_t tokens = {
@@ -778,7 +778,6 @@ static match_table_t tokens = { {Opt_quota, "quota"}, {Opt_usrquota, "usrquota"}, {Opt_barrier, "barrier=%u"}, - {Opt_extents, "extents"}, {Opt_err, NULL}, {Opt_resize, "resize"}, };
@@ -1111,9 +1110,6 @@ clear_qf_name:case Opt_bh:clear_opt (sbi->s_mount_opt,NOBH );break ; -case Opt_extents: -set_opt (sbi->s_mount_opt,EXTENTS ); -break ;default :printk (KERN_ERR "EXT4-fs: Unrecognized mount option \"%s\" "
include/linux/ext4_fs.h +0 -1
@@ -399,7 +399,6 @@ struct ext4_inode {#define EXT4_MOUNT_QUOTA 0x80000/* Some quota option set */ #define EXT4_MOUNT_USRQUOTA 0x100000/* "old" user quota */ #define EXT4_MOUNT_GRPQUOTA 0x200000/* "old" group quota */ -#define EXT4_MOUNT_EXTENTS 0x400000/* Extents support */ /* Compatibility, for having both ext2_fs.h and ext4_fs.h included at once */ #ifndef _LINUX_EXT2_FS_H
include/linux/ext4_jbd2.h +1 -1
@@ -33,7 +33,7 @@#define EXT4_SINGLEDATA_TRANS_BLOCKS (sb) \ (EXT4_HAS_INCOMPAT_FEATURE(sb, EXT4_FEATURE_INCOMPAT_EXTENTS) \ - || test_opt(sb, EXTENTS) ? 27U : 8U) + ? 27U : 8U)/* Extended attribute operations touch at most two data buffers, * two bitmap buffers, and two group summaries, in addition to the inode
Signature · 2 lines
David Kleikamp IBM Linux Technology Center
Re: [PATCH] Get rid of extents mount option - try 2
Quoted 2 lines · On Fri, 06 Oct 2006 16:21:40 -0500 Dave Kleikamp <[email protected]> wrote:
Enabling an ext4 file system to use extents should be done with 'tune2fs -O extents' or 'mke2fs -O extents', not with a mount option
But the mke2fs which I built by applying
http://www.bullopensource.org/ext4/20060926/ to e2fsprogs-1.39 doesn't recognise -O extents'. So the only way I can use extents is mount -o extents'.
What am I missing here?
Re: [PATCH] Get rid of extents mount option - try 2
Quoted 6 lines · Andrew Morton
Quoted 2 lines · On Fri, 06 Oct 2006 16:21:40 -0500 Dave Kleikamp <[email protected]> wrote:
Enabling an ext4 file system to use extents should be done with 'tune2fs -O extents' or 'mke2fs -O extents', not with a mount option
Quoted 6 lines
But the mke2fs which I built by applying
http://www.bullopensource.org/ext4/20060926/ to e2fsprogs-1.39 doesn't recognise-O extents'. So the only way I can use extents ismount -o extents'.What am I missing here?
To be honest, I've been lazy and I haven't even tried to get the new e2fsprogs. I just grabbed the latest from the mercurial repository,
http://e2fsprogs.sourceforge.net/e2fsprogs-hacking.html , and it doesn't work for me either. Ted?
Hold off on the patch until we figure it out. :-)
Shaggy
Signature · 2 lines
David Kleikamp IBM Linux Technology Center
Theodore Tso
maintainerRe: [PATCH] Get rid of extents mount option - try 2
Quoted 6 lines · Dave Kleikamp
To be honest, I've been lazy and I haven't even tried to get the new e2fsprogs. I just grabbed the latest from the mercurial repository,
http://e2fsprogs.sourceforge.net/e2fsprogs-hacking.html , and it doesn't work for me either. Ted?Hold off on the patch until we figure it out. :-)
I've been busy cleaning up the userspace extents patches before I'm willing to accept them into the mainline e2fsprogs tree. So it's not yet in Mercurial yet. It's coming soon; but in the meantime, my interim patchset which I've been using to hack on the extents patches plus signed-char-powerpc-dirhash problem can be found at:
ftp://ftp.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs-interim
Both a rolled-up patch file plus a broken-out tar.gz file are available there. The current version on the above URL is e2fsprogs-1.39-tyt1. Note that you will have to take the f_extents/image.gz from the broken-out tar file and copy it into tests/f_extents/image.gz or the f_extents regression test will fail. In addition, the f_lotsbad test regression test is also known to fail in 1.39-tyt1, and that regression test failure can be safely ignored for now.
This should be good enough for the extents patches that Shaggy has been queuing up.
- Ted
P.S. Before we add the extents patch, I just thought of one additional change that might be good to add. Could we add an u32 field in the superblock which counts the number of files with extents, and is automatically incremented and decremented as necessary by the kernel, and which can be checked by e2fsck? It would be really useful for making it easy for tune2fs to be able to tell if it can safely remove the extents feature from the filesystem, or whether it should refuse such a request.
Re: [PATCH] Get rid of extents mount option - try 2
Quoted 25 lines · Theodore Tso
Quoted 6 lines · Dave Kleikamp
To be honest, I've been lazy and I haven't even tried to get the new e2fsprogs. I just grabbed the latest from the mercurial repository,
http://e2fsprogs.sourceforge.net/e2fsprogs-hacking.html , and it doesn't work for me either. Ted?Hold off on the patch until we figure it out. :-)
I've been busy cleaning up the userspace extents patches before I'm willing to accept them into the mainline e2fsprogs tree. So it's not yet in Mercurial yet. It's coming soon; but in the meantime, my interim patchset which I've been using to hack on the extents patches plus signed-char-powerpc-dirhash problem can be found at:
ftp://ftp.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs-interim
Both a rolled-up patch file plus a broken-out tar.gz file are available there. The current version on the above URL is e2fsprogs-1.39-tyt1. Note that you will have to take the f_extents/image.gz from the broken-out tar file and copy it into tests/f_extents/image.gz or the
f_extentsregression test will fail. In addition, thef_lotsbadtest regression test is also known to fail in 1.39-tyt1, and that regression test failure can be safely ignored for now.
Quoted 2 lines
This should be good enough for the extents patches that Shaggy has been queuing up.
I noticed we are missing Documentation/filesystems/ext4.txt. Over the weekend, I'll try to put something together with instructions on getting the right version of e2fsprogs, etc.
Quoted 8 lines
P.S. Before we add the extents patch, I just thought of one additional change that might be good to add. Could we add an u32 field in the superblock which counts the number of files with extents, and is automatically incremented and decremented as necessary by the kernel, and which can be checked by e2fsck? It would be really useful for making it easy for tune2fs to be able to tell if it can safely remove the extents feature from the filesystem, or whether it should refuse such a request.
I guess this would be useful to turn the feature off immediately after turning it on, but with the removal of the extents mount option, we no longer have the ability to make old-style files once the feature is turned on. So it's unlikely that you'd be able to turn the feature off once a file system has been used.
Also, do we update the superblock in every transaction that creates or deletes a file? Otherwise, how do we guarantee the count is accurate after replaying the journal?
Shaggy
Signature · 2 lines
David Kleikamp IBM Linux Technology Center
Theodore Tso
maintainerRe: [PATCH] Get rid of extents mount option - try 2
Quoted 3 lines · Dave Kleikamp
I noticed we are missing
Documentation/filesystems/ext4.txt. Over the weekend, I'll try to put something together with instructions on getting the right version of e2fsprogs, etc.
For now just say to grab the latest from:
ftp://ftp.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs-interim
We'll have to upgrade it once we have a released version of e2fsprogs that supports extents (although by then we may need e2fsprogs-interim for 48 or 64 bit extents, or whatever next new feature we're working on :-).
Quoted 5 lines
I guess this would be useful to turn the feature off immediately after turning it on, but with the removal of the extents mount option, we no longer have the ability to make old-style files once the feature is turned on. So it's unlikely that you'd be able to turn the feature off once a file system has been used.
Well, we could have tune2fs scan all inodes, and have it allocate triple/double/indirect blocks to replace the extent tree, at some point. The count would allow us to turn it off immediately after turning it on without forcing the full scan of all inodes. Maybe it's not worth the overhead though.
Quoted 3 lines
Also, do we update the superblock in every transaction that creates or deletes a file? Otherwise, how do we guarantee the count is accurate after replaying the journal?
Yes, we do. The number of free inodes has to be kept up-to-date, after all, so the superblock is marked dirty and as being part of the transaction.
- Ted
Re: [PATCH] Get rid of extents mount option - try 2
Quoted 5 lines
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Theodore Tso (TT) writes:
Also, do we update the superblock in every transaction that creates or deletes a file? Otherwise, how do we guarantee the count is accurate after replaying the journal?
TT> Yes, we do. The number of free inodes has to be kept up-to-date, TT> after all, so the superblock is marked dirty and as being part of the TT> transaction.
actually, not any more. we use group descriptors to initialize free inodes counter at mount time.
thanks, Alex
Re: [PATCH] Get rid of extents mount option - try 2
In reply to Theodore TsoQuoted 7 lines · On Sat, 7 Oct 2006 13:20:27 -0400 Theodore Tso <[email protected]> wrote:
Quoted 3 lines
Also, do we update the superblock in every transaction that creates or deletes a file? Otherwise, how do we guarantee the count is accurate after replaying the journal?
Yes, we do. The number of free inodes has to be kept up-to-date, after all, so the superblock is marked dirty and as being part of the transaction.
Actually we cheat, and we don't keep the superblock free inodes counter up to date in real time. Done for CPU consumptions reasons, but it was perhaps a false optimisation, given that we still have a system-wide inode_lock.
The free inode count is already triply redundant: inode table scan, inode bitmap scan, ext4_group_desc.bg_free_inodes_count. Making it quadruply redundant seemed a bit over the top.
At runtime the definitive free-inodes count is the sum of the per-blockgroup free-inode counts. On clean shutdown we regenerate that and write it into the superblock.
Re: [PATCH] Get rid of extents mount option - try 2
In reply to Theodore TsoQuoted 8 lines · Theodore Tso
Quoted 3 lines · Dave Kleikamp
I noticed we are missing
Documentation/filesystems/ext4.txt. Over the weekend, I'll try to put something together with instructions on getting the right version of e2fsprogs, etc.For now just say to grab the latest from:
ftp://ftp.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs-interim
Ted,
Do you think it's possible to put a source tarball out there with the patches applied? It's confusing to untar the tarball only to find the patchset. Otherwise, we'll have to beef up the instructions a little bit.
Thanks,
Shaggy
Signature · 2 lines
David Kleikamp IBM Linux Technology Center
Theodore Tso
maintainerRe: [PATCH] Get rid of extents mount option - try 2
Quoted 8 lines · Dave Kleikamp
Quoted 7 lines · Theodore Tso
Quoted 3 lines · Dave Kleikamp
I noticed we are missing
Documentation/filesystems/ext4.txt. Over the weekend, I'll try to put something together with instructions on getting the right version of e2fsprogs, etc.For now just say to grab the latest from:
Quoted 7 lines
Quoted 1 line
ftp://ftp.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs-interim
Ted,
Do you think it's possible to put a source tarball out there with the patches applied? It's confusing to untar the tarball only to find the patchset. Otherwise, we'll have to beef up the instructions a little bit.
I was assuming that someone who knew out how to deal with -mm patchset would know how to deal with with a patchset. I agree it should be changed to e2fsprogs-1.39-tyt1-broken-out.tar.gz, though.
We can put a source tarball up, but sometimes the e2fsprogs-interim patches will be, well, about as stable as the -mm tree. So people who assume a completely stable release may end up being a little disappointed. Hopefully by the time the ext4 stuff gets merged into the mainline kernel we'll have a e2fsprogs-WIP release which will support extents, and then we can tell people to use that....
- - Ted
Re: [PATCH] Get rid of extents mount option - try 2
Quoted 17 lines · On Tue, 10 Oct 2006 17:07:18 -0400 Theodore Tso <[email protected]> wrote:
Quoted 8 lines · Dave Kleikamp
Quoted 7 lines · Theodore Tso
Quoted 3 lines · Dave Kleikamp
I noticed we are missing
Documentation/filesystems/ext4.txt. Over the weekend, I'll try to put something together with instructions on getting the right version of e2fsprogs, etc.For now just say to grab the latest from:
Quoted 7 lines
Quoted 1 line
ftp://ftp.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs-interim
Ted,
Do you think it's possible to put a source tarball out there with the patches applied? It's confusing to untar the tarball only to find the patchset. Otherwise, we'll have to beef up the instructions a little bit.
Quoted 6 lines
I was assuming that someone who knew out how to deal with -mm patchset would know how to deal with with a patchset. I agree it should be changed to e2fsprogs-1.39-tyt1-broken-out.tar.gz, though.
We can put a source tarball up, but sometimes the e2fsprogs-interim patches will be, well, about as stable as the -mm tree.
So put a stable one up ;)
Are people likely to care about e2fsprogs much? They'll just want to do mkfs, maybe the occasional fsck. At this stage it's the kernel code we want people to beat on.
Quoted 5 lines
So people who
assume a completely stable release may end up being a little disappointed. Hopefully by the time the ext4 stuff gets merged into the mainline kernel we'll have a e2fsprogs-WIP release which will support extents, and then we can tell people to use that....
I hope you didn't have anything else planned for this evening ;)
Re: [PATCH] Get rid of extents mount option - try 2
In reply to Dave KleikampQuoted 4 lines · Dave Kleikamp
EXT4: Get rid of extents mount option
Enabling an ext4 file system to use extents should be done with 'tune2fs -O extents' or 'mke2fs -O extents', not with a mount option
I would agree that the presence of INCOMPAT_EXTENTS should imply the EXTENTS mount option, but it is also desirable to be able to turn this off for testing. In our internal patches we also have a "noextents" mount option to disable extents at runtime even if "extents" was given as a default mount option.
So, I would leave most of the code as-is (with "test_opt(sb, EXTENTS)"), and just have ext3_fill_super() enable EXT4_MOUNT_EXTENTS if INCOMPAT_EXTENTS is set. This is a tiny bit tricky since parse_options() is called before the superblock is read, so I suspect we'll need a separate EXT4_MOUNT_NOEXTENTS to distinguish between no mount "extents" option given and "noextents" disabling this.
The Opt_noextents handling would clear EXT4_MOUNT_EXTENTS, and vice versa.
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.
If you mount the filesystem with -t ext4dev -o extents' then create some extenty files, then unount it and then mount it without -o extents', the driver will then refuse to create extenty files.
IOW: you need to give it `-o extents' each time.
That seems fairly pointless. In fact, if I'd created the fs with mke2fs -O extents' (which doesn't work at present) then I'd expect it to use extents from thereon after, without requiring mount -o extents'.
Quoted 9 lines · Andrew Morton
If you mount the filesystem with
-t ext4dev -o extents' then create some extenty files, then unount it and then mount it without-o extents', the driver will then refuse to create extenty files.IOW: you need to give it `-o extents' each time.
That seems fairly pointless. In fact, if I'd created the fs with
mke2fs -O extents' (which doesn't work at present) then I'd expect it to use extents from thereon after, without requiringmount -o extents'.
I think this is an oversight. For Lustre we wanted the ability to mount ext3 filesystems with or without extents, because different customers have different levels of tolerance for risk. These days all of our customers use extents (better performance in conjunction with mballoc), but the patches have not been changed for ext4 (which should really default to using extents on a filesystem with the INCOMPAT_EXTENT feature set unless told otherwise). That is a necessity for filesystems larger than 2^32 blocks, since there is no way to create old block-mapped files past that limit.
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.
Quoted 5 lines · On Thu, 5 Oct 2006 23:58:29 -0600 Andreas Dilger <[email protected]> wrote:
but the patches have not been changed for ext4 (which should really default to using extents on a filesystem with the
INCOMPAT_EXTENTfeature set unless told otherwise). That is a necessity for filesystems larger than 2^32 blocks, since there is no way to create old block-mapped files past that limit.
That's news to me. So we only use 48-bit block numbers for extents and not for old-style indirect blocks?
How much performance improvement do they get, btw? CPU or IO? I'm not noticing any difference.
Has been a while since I did any fs testing. Boy, ext3 is beating the crap out of ext2 for quality of file layout.
Quoted 10 lines · Andrew Morton
Quoted 5 lines · On Thu, 5 Oct 2006 23:58:29 -0600 Andreas Dilger <[email protected]> wrote:
but the patches have not been changed for ext4 (which should really default to using extents on a filesystem with the
INCOMPAT_EXTENTfeature set unless told otherwise). That is a necessity for filesystems larger than 2^32 blocks, since there is no way to create old block-mapped files past that limit.That's news to me. So we only use 48-bit block numbers for extents and not for old-style indirect blocks?
Correct. The block-mapped {d,t,}indirect blocks chewed up enough space as it was (0.1% of the file size) without doubling the block pointers. Things like truncate hurt pretty badly because of that, as does the increased IO load to read them and memory pressure due to keeping them in RAM.
Quoted 2 lines
How much performance improvement do they get, btw? CPU or IO? I'm not noticing any difference.
As mentioned in my other email, the big performance win will come from the multi-block allocation (mballoc) and delayed allocation (delalloc) from Alex.
The mballoc patch allows a 1MB write to get a 1MB-aligned and contiguous chunk of disk, instead of the next 256 blocks that might be free. Having 1MB alignment is good for 10% or more on some RAID systems to avoid writing partial stripes (which also requires a read).
Delalloc allows the filesystem to actually submit 1MB writes at once without doing the block allocation in prepare_write(). Better for picking free space, and avoids needless extent tree insertion/rebalancing.
Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.