From: "Darrick J. Wong" <darrick.wong@oracle.com>
To: Artem Blagodarenko <artem.blagodarenko@gmail.com>
Cc: linux-ext4@vger.kernel.org, adilger.kernel@dilger.ca,
alexey.lyashkov@gmail.com
Subject: Re: [PATCH] libext2fs: readahead for meta_bg
Date: Tue, 28 Feb 2017 08:16:02 -0800 [thread overview]
Message-ID: <20170228161602.GD5266@birch.djwong.org> (raw)
In-Reply-To: <1487585025-16654-1-git-send-email-artem.blagodarenko@gmail.com>
On Mon, Feb 20, 2017 at 01:03:45PM +0300, Artem Blagodarenko wrote:
> From: Alexey Lyashkov <alexey.lyashkov@seagate.com>
>
> There are ~37k of random IOs with meta_bg option on 300T target.
Yikes, 300TB ext4! :)
(Is that really 2.2 million blockgroups?)
> Debugfs requires 20 minutes to be started. Enabling readahead for
> group blocks metadata save time dramatically. Only 12s to start.
>
> Signed-off-by: Alexey Lyashkov <alexey.lyashkov@seagate.com>
Looks good,
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
--D
> ---
> lib/ext2fs/openfs.c | 6 ++++++
> 1 files changed, 6 insertions(+), 0 deletions(-)
>
> diff --git a/lib/ext2fs/openfs.c b/lib/ext2fs/openfs.c
> index ba501e6..f158b0a 100644
> --- a/lib/ext2fs/openfs.c
> +++ b/lib/ext2fs/openfs.c
> @@ -399,6 +399,12 @@ errcode_t ext2fs_open2(const char *name, const char *io_options,
> #endif
> dest += fs->blocksize*first_meta_bg;
> }
> +
> + for (i = first_meta_bg ; i < fs->desc_blocks; i++) {
> + blk = ext2fs_descriptor_block_loc2(fs, group_block, i);
> + io_channel_cache_readahead(fs->io, blk, 1);
> + }
> +
> for (i=first_meta_bg ; i < fs->desc_blocks; i++) {
> blk = ext2fs_descriptor_block_loc2(fs, group_block, i);
> retval = io_channel_read_blk64(fs->io, blk, 1, dest);
> --
> 1.7.1
>
next prev parent reply other threads:[~2017-02-28 16:16 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-20 10:03 [PATCH] libext2fs: readahead for meta_bg Artem Blagodarenko
2017-02-28 16:16 ` Darrick J. Wong [this message]
2017-03-01 0:10 ` Andreas Dilger
2017-03-01 2:19 ` Alexey Lyashkov
2017-03-01 2:50 ` Andreas Dilger
2017-03-01 4:02 ` Alexey Lyashkov
2017-03-01 4:35 ` Andreas Dilger
2017-03-03 9:15 ` [PATCH] libext2fs: preload block group on request Artem Blagodarenko
2017-03-04 0:45 ` [PATCH, RFC] " Andreas Dilger
2017-03-03 13:01 ` [PATCH v2] " Artem Blagodarenko
2017-03-01 20:05 ` [PATCH] libext2fs: readahead for meta_bg Theodore 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=20170228161602.GD5266@birch.djwong.org \
--to=darrick.wong@oracle.com \
--cc=adilger.kernel@dilger.ca \
--cc=alexey.lyashkov@gmail.com \
--cc=artem.blagodarenko@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).