From: "Theodore Y. Ts'o" <tytso@mit.edu>
To: Shyam Prasad N <nspmangalore@gmail.com>
Cc: David Howells <dhowells@redhat.com>,
Steve French <smfrench@gmail.com>,
linux-ext4@vger.kernel.org
Subject: Re: Regarding ext4 extent allocation strategy
Date: Tue, 13 Jul 2021 16:18:01 -0400 [thread overview]
Message-ID: <YO30+XRGAYnME+vy@mit.edu> (raw)
In-Reply-To: <CANT5p=qi8-9iZa0XE70ZaCUdqscKufovjcUAZZPDRmN9W5_uQA@mail.gmail.com>
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
next prev parent reply other threads:[~2021-07-13 20:18 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 [this message]
2021-07-14 0:37 ` Shyam Prasad N
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=YO30+XRGAYnME+vy@mit.edu \
--to=tytso@mit.edu \
--cc=dhowells@redhat.com \
--cc=linux-ext4@vger.kernel.org \
--cc=nspmangalore@gmail.com \
--cc=smfrench@gmail.com \
/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