mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: mel@skynet.ie (Mel Gorman)
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Mariusz Kozlowski <m.kozlowski@tuxland.pl>, linux-kernel@vger.kernel.org
Subject: Re: 2.6.21-rc3-mm1
Date: Thu, 15 Mar 2007 10:16:25 +0000	[thread overview]
Message-ID: <20070315101625.GA16974@skynet.ie> (raw)
In-Reply-To: <20070314170738.d5d35c06.akpm@linux-foundation.org>

On (14/03/07 17:07), Andrew Morton didst pronounce:
> > On Wed, 14 Mar 2007 20:06:02 +0100 Mariusz Kozlowski <m.kozlowski@tuxland.pl> wrote:
> > Hello,
> > 
> > 	Today after +- 24h of uptime I found some more page allocation
> > failures ('eth1: Can't allocate skb for Rx'). You'll find more here:
> > 
> > http://tuxland.pl/misc/2.6.21-rc3-mm1-page-allocation-failure.txt
> > 
> > System wasn't doing anything unusual, as usual ;-) X, some p2p 
> > software, firefox+flash playing music.
> > 
> 
> Do other kernels do this, or is 2.6.21-rc3-mm1 worse?
> 
> It is of course a non-fatal problem and will inevitably happen sometimes,
> but we would like the VM to be able to minimise the occurrence of this
> problem.
> 

I'm looking at this now. In the vanilla allocator, min_free_kbytes has the
effect of keeping largest blocks free for as long as possible. This means
that if high-order allocations are rare, they'll tend to succeed up to a point.

In the case of the earlier report on HID failing the order-5 allocation, it's
because we didn't reclaim for long enough because the order was too high. It
would need to reclaim for quite a long time before it would get an order-5
block free. That is what Andy's lumpy-reclaim patches address - reclaiming
intelligently when we know it has a chance of succeeding instead of giving up.

> I think we were rather hoping that Mel's anti-fragmentation work would
> improve things.

I'm still optimistic it will. This is the widest it's been tested so far
so there were going to be bases

In this case, the order is high but GFP_ATOMIC. These allocations get grouped
together but with a low min_free_kbytes, as is the case on this machine,
the high-order atomic blocks eventually get used by others. I had assumed
that if high-order atomic allocations were important (e.g. e1000) that the
machine would be configured with min_free_kbytes of at least 16384 i.e.
1 MAX_ORDER_NR_PAGES per MIGRATE_TYPE.

Mariusz, I would be interested in finding out if this problem still occurs when
you set min_free_kbytes to 16384 via /proc/sys/vm/min_free_kbytes. I understand
that the problem is not easily reproduced and requiring configuration changes
is far from ideal but it'd allow me to find out if options 2 or 3 below make
sense in advance.

I'm looking at three ways of addressing this;

1. Anti-fragmentation currently favours breaking larger blocks to
   group-by-mobility as opposed to the vanilla allocator which always favours
   using the smallest possible block no matter where it is.  I'm looking
   at preserving the behaviour of the vanilla allocator to keeping larger
   blocks free as much as possible to see how adverse an effect that
   subsequently has on fragmentation.

2. Set min_free_kbytes higher automatically at boot time when
   CONFIG_PAGE_GROUP_BY_MOBILITY is set.

3. Disable PAGE_GROUP_BY_MOBILITY when min_free_kbytes is set too low
   and print KERN_INFO messages when it's disabled or enabled based on
   min_free_kbytes

I'm testing patches for 1 at the moment even though I think it will
lower success rates for superpage allocations because of increased
fragmentation. Benchmarking will tell me for sure.

Thanks Mariusz for the report.

-- 
Mel Gorman
Part-time Phd Student                          Linux Technology Center
University of Limerick                         IBM Dublin Software Lab

  parent reply	other threads:[~2007-03-15 10:16 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-08  4:18 2.6.21-rc3-mm1 Andrew Morton
2007-03-08  9:59 ` ext4, wireless (was Re: 2.6.21-rc3-mm1) Jeff Garzik
2007-03-08 14:50 ` 2.6.21-rc3-mm1 John W. Linville
2007-03-08 16:37   ` 2.6.21-rc3-mm1 Dave Jones
2007-03-08 17:56 ` 2.6.21-rc3-mm1 Valdis.Kletnieks
2007-03-08 18:34   ` 2.6.21-rc3-mm1 John W. Linville
2007-03-08 20:27     ` 2.6.21-rc3-mm1 Valdis.Kletnieks
2007-03-08 20:50 ` 2.6.21-rc3-mm1 Michal Piotrowski
2007-03-10  2:18   ` 2.6.21-rc3-mm1 Andrew Morton
2007-03-10 15:45     ` 2.6.21-rc3-mm1 Paul E. McKenney
     [not found]       ` <6bffcb0e0703111002t75a8ac51vcce7d52684e04a9d@mail.gmail.com>
2007-03-12  4:41         ` 2.6.21-rc3-mm1 Paul E. McKenney
2007-03-09 11:40 ` 2.6.21-rc3-mm1 Frederik Deweerdt
2007-03-15  9:22   ` ipw2200: can't load firmware (was Re: 2.6.21-rc3-mm1) Frederik Deweerdt
2007-03-10  8:33 ` 2.6.21-rc3-mm1 Mariusz Kozlowski
2007-03-10  8:48   ` 2.6.21-rc3-mm1 Mariusz Kozlowski
2007-03-10  8:58   ` 2.6.21-rc3-mm1 Andrew Morton
2007-03-10  9:18     ` 2.6.21-rc3-mm1 Greg KH
2007-03-10 12:43       ` 2.6.21-rc3-mm1 Jiri Kosina
2007-03-10 15:36         ` 2.6.21-rc3-mm1 Mariusz Kozlowski
2007-03-10 16:00           ` [linux-usb-devel] 2.6.21-rc3-mm1 Alan Stern
2007-03-10 16:36             ` Mariusz Kozlowski
2007-03-10 19:02               ` Alan Stern
2007-03-12 20:50                 ` Mariusz Kozlowski
2007-03-12 20:53                   ` Jiri Kosina
2007-03-10 13:32 ` 2.6.21-rc3-mm1 Mariusz Kozlowski
2007-03-12 18:14 ` 2.6.21-rc3-mm1 Radoslaw Szkodzinski
2007-03-14 19:06 ` 2.6.21-rc3-mm1 Mariusz Kozlowski
2007-03-15  1:07   ` 2.6.21-rc3-mm1 Andrew Morton
2007-03-15  6:09     ` 2.6.21-rc3-mm1 Mariusz Kozlowski
2007-03-15 10:16     ` Mel Gorman [this message]
2007-03-15 15:37       ` 2.6.21-rc3-mm1 Mariusz Kozlowski
2007-03-15 19:59         ` 2.6.21-rc3-mm1 Mel Gorman
2007-03-16  6:43           ` 2.6.21-rc3-mm1 Mariusz Kozlowski
2007-03-16 10:03             ` 2.6.21-rc3-mm1 Mel Gorman
2007-03-17 18:26     ` [PATCH] Bias the location of pages freed for min_free_kbytes in the same MAX_ORDER_NR_PAGES blocks Mel Gorman
2007-03-18  8:22       ` Andrew Morton
2007-03-18 11:35         ` Mel Gorman
2007-03-18 18:12           ` Andrew Morton
2007-03-18 19:05             ` Mel Gorman
2007-03-18 19:28               ` Andrew Morton
2007-03-18 20:08                 ` Mel Gorman
2007-03-18 20:45                   ` Andrew Morton
2007-03-18 22:21                     ` Mel Gorman

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=20070315101625.GA16974@skynet.ie \
    --to=mel@skynet.ie \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m.kozlowski@tuxland.pl \
    /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®