From: Duncan <1i5t5.duncan@cox.net>
To: linux-btrfs@vger.kernel.org
Subject: Re: Btrfsck memory usage reduce idea
Date: Mon, 21 Mar 2016 09:43:09 +0000 (UTC) [thread overview]
Message-ID: <pan$4aef4$19f8b299$f561cb94$e137c056@cox.net> (raw)
In-Reply-To: 56EF595B.7080509@cn.fujitsu.com
Qu Wenruo posted on Mon, 21 Mar 2016 10:15:55 +0800 as excerpted:
> The point that I didn't want to keep the current behavior is, the old
> one is just OK or OOM, no one would know if it will OOM until it
> happens.
>
> But the new one would be much flex than current behavior.
> As it fully uses the IO cache provided by kernel.
>
> For machine with lot of memory, the whole IO will be cached except the
> first read.
> Making the difference between new and old implementation quite small.
>
> For machine with less memory or the fs is just too large, at least
> btrfsck won't cause OOM.
That makes more sense to me, now.
I didn't initially post but I was worried about the tradeoff to much
longer times, tho with lower memory requirements, on operations that can
already take a long time. But if as you say here the new, lower memory
version makes use of cache so there shouldn't be a lot of difference on
higher memory machines anyway, then yes, replacing the current
implementation instead of providing an option so either implementation
can be used, makes more sense, because otherwise one option will get more
testing than the other, fixes to one might not carry over to the other,
etc.
Tho as you suggest, possibly with a transition period during which both
implementations are available, to work out any differences in results and/
or dramatically worse runtime cases.
Thanks. =:^)
--
Duncan - List replies preferred. No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master." Richard Stallman
next prev parent reply other threads:[~2016-03-21 9:43 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-07 5:42 Btrfsck memory usage reduce idea Qu Wenruo
2016-03-08 8:28 ` Satoru Takeuchi
2016-03-08 8:46 ` Qu Wenruo
2016-03-09 0:13 ` Satoru Takeuchi
2016-03-18 18:18 ` David Sterba
2016-03-21 2:15 ` Qu Wenruo
2016-03-21 9:43 ` Duncan [this message]
2016-03-22 14:49 ` David Sterba
2016-03-23 1:12 ` Qu Wenruo
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='pan$4aef4$19f8b299$f561cb94$e137c056@cox.net' \
--to=1i5t5.duncan@cox.net \
--cc=linux-btrfs@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).