From: Michal Hocko <mhocko@suse.cz>
To: Cong Wang <xiyou.wangcong@gmail.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>,
Greg KH <gregkh@linuxfoundation.org>,
LKML <linux-kernel@vger.kernel.org>,
stable@vger.kernel.org
Subject: Re: Please backport commit 3812c8c8f39 to stable
Date: Tue, 7 Oct 2014 14:23:36 +0200 [thread overview]
Message-ID: <20141007122336.GB14243@dhcp22.suse.cz> (raw)
In-Reply-To: <CAM_iQpW4t_jKSCbS5J1N15FFChd=-UK3QOXrjjst64Rqe5KBTw@mail.gmail.com>
On Fri 03-10-14 11:03:30, Cong Wang wrote:
> On Fri, Oct 3, 2014 at 8:13 AM, Michal Hocko <mhocko@suse.cz> wrote:
> >
> > That commit fixes an OOM deadlock. Not a soft lockup. Do you have the
> > OOM killer report from the log? This would tell us that the killed task
> > was indeed sleeping on the lock which is hold by the charger which
> > triggered the OOM. I am little bit surprised that I do not see any OOM
> > related functions on the stacks (maybe the code is inlined...).
>
>
> Oh, did you see __mem_cgroup_try_charge() calls
> schedule_timeout_uninterruptible() in stack trace? Yes, they are inlined
> and I don't see any other possibilities for calling it.
Yes the only place we call schedule_timeout_uninterruptible from is
mem_cgroup_handle_oom. And it happens only for a task which hasn't been
killed by OOM killer.
> > It would be better to know what exactly is going on before backporting
> > this change because it is quite large.
> >
>
> I thought the stack trace I showed is obvious. :) I am very happy
> to investigate if you see any other path calling
> schedule_timeout_uninterruptible()
> in __mem_cgroup_try_charge().
I was expecting an oom report which kills a task which is sleeping on a
lock which is held on the way up to the charge function. Your report
mentioned a task waiting for i_mutex for too long. It is true that the
charging path is holding an i_mutex as well so it might be the same
situation handled by the said patch. But it is not 100% clear this is
the case without an OOM report which would point to the waiting task.
The memcg might be trashing on the hard limit and reclaim might take a
long time.
--
Michal Hocko
SUSE Labs
prev parent reply other threads:[~2014-10-07 12:23 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-30 3:43 Cong Wang
2014-09-30 8:16 ` Michal Hocko
2014-09-30 17:14 ` Cong Wang
2014-10-02 21:04 ` Cong Wang
2014-10-03 15:37 ` Michal Hocko
2014-10-03 18:16 ` Cong Wang
2014-10-03 20:36 ` Cong Wang
2014-10-07 12:33 ` Michal Hocko
2014-10-09 4:56 ` Cong Wang
2014-10-03 15:13 ` Michal Hocko
2014-10-03 18:03 ` Cong Wang
2014-10-07 12:23 ` Michal Hocko [this message]
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=20141007122336.GB14243@dhcp22.suse.cz \
--to=mhocko@suse.cz \
--cc=gregkh@linuxfoundation.org \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=stable@vger.kernel.org \
--cc=xiyou.wangcong@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
all inboxes | Powered by JetHome®