From: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
To: david@fromorbit.com
Cc: arekm@maven.pl, htejun@gmail.com, cl@linux.com, mhocko@suse.com,
linux-mm@kvack.org, xfs@oss.sgi.com
Subject: Re: memory reclaim problems on fs usage
Date: Fri, 13 Nov 2015 21:19:46 +0900 [thread overview]
Message-ID: <201511132119.BAG65154.QVHStOOFFMOLFJ@I-love.SAKURA.ne.jp> (raw)
In-Reply-To: <20151112200641.GR19199@dastard>
Dave Chinner wrote:
> So why have we only scanned *176* pages* during reclaim? On other
> OOM reports in this trace it's as low as 12. Either that stat is
> completely wrong, or we're not doing sufficient page LRU reclaim
> scanning....
>
> > [ 9662.234685] MemAlloc-Info: 3 stalling task, 0 dying task, 0 victim task.
> >
> > vmstat_update() and submit_flushes() remained pending for about 110 seconds.
> > If xlog_cil_push_work() were spinning inside GFP_NOFS allocation, it should be
> > reported as MemAlloc: traces, but no such lines are recorded. I don't know why
> > xlog_cil_push_work() did not call schedule() for so long.
>
> I'd say it is repeatedly waiting for IO completion on log buffers to
> write out the checkpoint. It's making progress, just if it's taking
> multiple second per journal IO it will take a long time to write a
> checkpoint. All the other blocked tasks in XFS inode reclaim are
> either waiting directly on IO completion or waiting for the log to
> complete a flush, so this really just looks like an overloaded IO
> subsystem to me....
The vmstat statistics can become wrong when vmstat_update() workqueue item
cannot be processed due to in-flight workqueue item not calling schedule().
If in-flight workqueue item (in this case xlog_cil_push_work()) called
schedule(), the pending vmstat_update() workqueue item will be processed
and the vmstat becomes up to dated. Like you expect that xlog_cil_push_work()
was waiting for IO completion on log buffers rather than spinning inside
GFP_NOFS allocation, what should happened is xlog_cil_push_work() called
schedule() and vmstat_update() was processed. But vmstat_update() remained
pending for about 110 seconds. That's strange...
Arkadiusz is trying http://marc.info/?l=linux-mm&m=144725782107096&w=2
which is for making sure that vmstat_update() workqueue item is processed
by changing wait_iff_congested() to call schedule(), and we are waiting
for test results.
Well, one of dependent patches "vmstat: explicitly schedule per-cpu work
on the CPU we need it to run on" might be relevant to this problem.
If http://sprunge.us/GYBb and http://sprunge.us/XWUX solve the problem
(for both with swap case and without swap case), the vmstat statistics
was wrong.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2015-11-13 12:20 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-10 22:13 Arkadiusz Miśkiewicz
2015-11-11 15:58 ` Tetsuo Handa
2015-11-11 16:19 ` Arkadiusz Miśkiewicz
2015-11-11 22:19 ` Tetsuo Handa
2015-11-12 6:06 ` Arkadiusz Miśkiewicz
2015-11-12 14:12 ` Tetsuo Handa
2015-11-12 20:06 ` Dave Chinner
2015-11-13 12:19 ` Tetsuo Handa [this message]
2015-11-12 21:28 ` Arkadiusz Miśkiewicz
2015-11-14 20:40 ` Arkadiusz Miśkiewicz
2015-11-15 2:35 ` Tetsuo Handa
2015-11-15 11:29 ` Arkadiusz Miśkiewicz
2015-11-15 14:13 ` Tetsuo Handa
2015-11-15 14:49 ` Arkadiusz Miśkiewicz
2015-11-16 16:15 ` Michal Hocko
2015-11-18 22:36 ` Arkadiusz Miśkiewicz
2015-11-19 15:59 ` Tetsuo Handa
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=201511132119.BAG65154.QVHStOOFFMOLFJ@I-love.SAKURA.ne.jp \
--to=penguin-kernel@i-love.sakura.ne.jp \
--cc=arekm@maven.pl \
--cc=cl@linux.com \
--cc=david@fromorbit.com \
--cc=htejun@gmail.com \
--cc=linux-mm@kvack.org \
--cc=mhocko@suse.com \
--cc=xfs@oss.sgi.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