From: Jan Kara <jack@suse.cz>
To: Gilad Ben-Yossef <gilad@benyossef.com>
Cc: Jan Kara <jack@suse.cz>,
Andrew Morton <akpm@linux-foundation.org>,
"Srivatsa S. Bhat" <srivatsa.bhat@linux.vnet.ibm.com>,
linux-fsdevel@vger.kernel.org,
LKML <linux-kernel@vger.kernel.org>,
hare@suse.de, Al Viro <viro@zeniv.linux.org.uk>,
Christoph Hellwig <hch@infradead.org>
Subject: Re: [PATCH] vfs: Avoid IPI storm due to bh LRU invalidation
Date: Tue, 7 Feb 2012 19:29:26 +0100 [thread overview]
Message-ID: <20120207182926.GD1043@quack.suse.cz> (raw)
In-Reply-To: <CAOtvUMcWOfkn401qEUgBMV=R-vCbWG3sus6=yV9kQjRhheXV4A@mail.gmail.com>
On Tue 07-02-12 18:25:18, Gilad Ben-Yossef wrote:
> On Tue, Feb 7, 2012 at 12:25 AM, Jan Kara <jack@suse.cz> wrote:
> > On Mon 06-02-12 13:17:17, Andrew Morton wrote:
> >> On Mon, 6 Feb 2012 17:47:32 +0100
> >> Jan Kara <jack@suse.cz> wrote:
> >>
> >> > On Mon 06-02-12 21:12:36, Srivatsa S. Bhat wrote:
> >> > > On 02/06/2012 07:25 PM, Jan Kara wrote:
> >> > >
> >> > > > When discovery of lots of disks happen in parallel, we call
> >> > > > invalidate_bh_lrus() once for each disk from partitioning code resulting in a
> >> > > > storm of IPIs and causing a softlockup detection to fire (it takes several
> >> > > > *minutes* for a machine to execute all the invalidate_bh_lrus() calls).
> >>
> >> Gad. How many disks are we talking about here?
> > I think something around hundred scsi disks in this case (number of
> > physical drives is actually lower but multipathing blows it up). I actually
> > saw machines with close to thousand scsi disks (yes, they had names like
> > sdabc ;).
>
> LOL. Is that a huge SCSI disk array in your server or your are just
> happy to see me... ? :-)
> >
> ...
> >> > >
> >> > > Something related that you might be interested in:
> >> > > https://lkml.org/lkml/2012/2/5/109
> >> > >
> >> > > (This is part of Gilad's patchset that tries to reduce cross-CPU IPI
> >> > > interference.)
> >> > Thanks for the pointer. I didn't know about it. As Hannes wrote, this
> >> > need not be enough for our use case as there might indeed be some bhs in
> >> > the LRU. But I'd be interested how well the patchset works anyway. Maybe it
> >> > would be enough because after all when we invalidate LRUs subsequent
> >> > callers will see them empty and not issue IPI? Hannes, can you give a try
> >> > to the patches?
>
> I think its worth a shot since the mutex just delays the IPIs instead
> of canceling them
> altogether.
Well, mutex will just delay callers but the sequence logic behind the
mutex will reduce number of IPIs a lot - all waiters for mutex will be
satisfied by a single signalling of all CPUs while previously they would
each do the signalling.
> A somewhat similar issue in the direct reclaim path of the buddy
> allocator trying to reclaim per cpu pages was causing a massive storm of
> IPIs during OOM with concurrent work loads and the IPI noise patches
> mitigate 85% of the IPIs sent just by checking to see if there are any
> per cpu pages on the CPU you are about to IPI, so maybe the same kind of
> logic applies here as well.
Honza
--
Jan Kara <jack@suse.cz>
SUSE Labs, CR
next prev parent reply other threads:[~2012-02-07 18:29 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-06 13:55 [PATCH] vfs: Avoid IPI storm due to bh LRU invalidation Jan Kara
2012-02-06 15:42 ` Srivatsa S. Bhat
2012-02-06 15:51 ` Hannes Reinecke
2012-02-06 16:47 ` Jan Kara
2012-02-06 21:17 ` Andrew Morton
2012-02-06 22:25 ` Jan Kara
2012-02-07 16:25 ` Gilad Ben-Yossef
2012-02-07 18:29 ` Jan Kara [this message]
2012-02-08 7:09 ` Gilad Ben-Yossef
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=20120207182926.GD1043@quack.suse.cz \
--to=jack@suse.cz \
--cc=akpm@linux-foundation.org \
--cc=gilad@benyossef.com \
--cc=hare@suse.de \
--cc=hch@infradead.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=srivatsa.bhat@linux.vnet.ibm.com \
--cc=viro@zeniv.linux.org.uk \
/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).