All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shyam Prasad N <nspmangalore@gmail.com>
To: "Theodore Y. Ts'o" <tytso@mit.edu>
Cc: David Howells <dhowells@redhat.com>,
	Steve French <smfrench@gmail.com>,
	linux-ext4@vger.kernel.org
Subject: Re: Regarding ext4 extent allocation strategy
Date: Wed, 14 Jul 2021 06:07:36 +0530	[thread overview]
Message-ID: <CANT5p=pGsU+rgyd-2m+ODOwkxDvdbZKi81DthuuQgzDUXZ9UAQ@mail.gmail.com> (raw)
In-Reply-To: <YO30+XRGAYnME+vy@mit.edu>

On Wed, Jul 14, 2021 at 1:48 AM Theodore Y. Ts'o <tytso@mit.edu> wrote:
>
> On Tue, Jul 13, 2021 at 06:27:37PM +0530, Shyam Prasad N wrote:
> >
> > Also, is this parameter also respected when a hole is punched in the
> > middle of an allocated data extent? i.e. is there still a possibility
> > that a punched hole does not translate to splitting the data extent,
> > even when extent_max_zeroout_kb is set to 0?
>
> Ext4 doesn't ever try to zero blocks as part of a punch operation.
> It's true a file system is allowed to do it, but I would guess most
> wouldn't, since the presumption is that userspace is actually trying
> to free up disk space, and so you would want to release the disk
> blocks in the punch hole case.
>
> The more interesting one is the FALLOC_FL_ZERO_RANGE_FL operation,
> which *should* work by transitioning the extent to be uninitialized,
> but there might be cases where writing a few zero blocks might be
> faster in some cases.  That should use the same code path which
> resepects the max_zeroout configuration parameter for ext4.
>
> Cheers,
>
>                                         - Ted

Thanks a lot for your replies, Ted. This was useful.

-- 
Regards,
Shyam

  reply	other threads:[~2021-07-14  0:37 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-13  6:52 Regarding ext4 extent allocation strategy Shyam Prasad N
2021-07-13 11:39 ` Theodore Y. Ts'o
2021-07-13 12:57   ` Shyam Prasad N
2021-07-13 20:18     ` Theodore Y. Ts'o
2021-07-14  0:37       ` Shyam Prasad N [this message]
2022-02-18  3:18   ` Gao Xiang
2022-02-22  2:48     ` Gao Xiang

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='CANT5p=pGsU+rgyd-2m+ODOwkxDvdbZKi81DthuuQgzDUXZ9UAQ@mail.gmail.com' \
    --to=nspmangalore@gmail.com \
    --cc=dhowells@redhat.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=smfrench@gmail.com \
    --cc=tytso@mit.edu \
    /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.