From: Ted Ts'o <tytso@mit.edu>
To: Lukas Czerner <lczerner@redhat.com>
Cc: linux-ext4@vger.kernel.org, adilger@dilger.ca
Subject: Re: [PATCH 2/5 v2] e2fsprogs: Use punch hole as "discard" on regular files
Date: Thu, 15 Sep 2011 23:50:56 -0400 [thread overview]
Message-ID: <20110916035056.GT28181@thunk.org> (raw)
In-Reply-To: <1313167380-3283-2-git-send-email-lczerner@redhat.com>
On Fri, Aug 12, 2011 at 06:42:57PM +0200, Lukas Czerner wrote:
> If e2fsprogs tools (mke2fs, e2fsck) is run on regular file instead of
> on block device, we can use punch hole instead of regular discard
> command which would not work on regular file anyway. This gives us
> several advantages. First of all when e2fsck is run with '-E discard'
> parameter it will punch out all ununsed space from the image, hence
> trimming down the file system image. And secondly, when creating an
> file system on regular file (with '-E discard' which is default), we
> can use punch hole to clear the file content, hence we can skip inode
> table initialization, because reads from sparse area returns zeros. This
> will result in faster file system creation (without the need to specify
> lazy_itable_init) and smaller images.
>
> This commit also fixes some tests that would fail due to mke2fs showing
> discard progress, hence the output would differ.
>
> Signed-off-by: Lukas Czerner <lczerner@redhat.com>
Applied to the next branch, thanks. (I combined the following patch
which added the configure.in test for linux/falloc.h, since it's
needed by this patch.)
- Ted
next prev parent reply other threads:[~2011-09-16 3:50 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-12 16:42 [PATCH 1/5 v2] e2fsprogs: create open() and stat() helpers Lukas Czerner
2011-08-12 16:42 ` [PATCH 2/5 v2] e2fsprogs: Use punch hole as "discard" on regular files Lukas Czerner
2011-09-16 3:50 ` Ted Ts'o [this message]
2011-08-12 16:42 ` [PATCH 3/5 v2] configure.in: add check for linux/falloc.h header Lukas Czerner
2011-08-12 16:42 ` [PATCH 4/5 v2] e2fsck: do not attempt to discard if -n was specified Lukas Czerner
2011-09-16 3:53 ` Ted Ts'o
2011-08-12 16:43 ` [PATCH 5/5 v2] tests: Print out list of failed tests Lukas Czerner
2011-09-16 3:56 ` Ted Ts'o
2011-09-01 8:39 ` [PATCH 1/5 v2] e2fsprogs: create open() and stat() helpers Lukas Czerner
2011-09-16 3:50 ` Ted Ts'o
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=20110916035056.GT28181@thunk.org \
--to=tytso@mit.edu \
--cc=adilger@dilger.ca \
--cc=lczerner@redhat.com \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.