All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dave Hansen <dave@linux.vnet.ibm.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Milos Jakovljevic <sukijaki@gmail.com>,
	bugzilla-daemon@bugzilla.kernel.org, linux-mm@kvack.org,
	Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>,
	Kyungmin Park <kyungmin.park@samsung.com>
Subject: 3.7-rc6 memory accounting problem (manifests like a memory leak)
Date: Sat, 17 Nov 2012 15:08:48 -0800	[thread overview]
Message-ID: <50A81900.8000801@linux.vnet.ibm.com> (raw)
In-Reply-To: <50A6D357.3070103@linux.vnet.ibm.com>

page_owner didn't help, at least not directly.  As the pages "leak",
they stop showing up in page_owner, which means they're in the
allocator.  Check out buddyinfo/meminfo:

> dave@nimitz:~/ltc/linux.git$ cat /proc/buddyinfo /proc/meminfo 
> Node 0, zone      DMA      0      0      0      1      2      1      1      0      1      1      3 
> Node 0, zone    DMA32  25450  13645  11665   2994   1242    665    234     50     12      1      1 
> Node 0, zone   Normal   6494  28630  16790   5872   3524   1666    844    238    146     60    398 
> MemTotal:        7825604 kB
> MemFree:         1285260 kB
...

Just the 398 order-10 zone Normal pages account for ~1.6GB of free
memory, yet the MemFree is ~1.3GB, and that's a *SINGLE* bucket in the
buddy allocator.  Adding them all up, it's fairly close to the amount of
memory that I'm missing at the moment.

Rather than being a real leak, it looks like this might just be an
accounting problem:

$ cat /proc/zoneinfo  | egrep 'free_pages|Node'
Node 0, zone      DMA
    nr_free_pages 3976
Node 0, zone    DMA32
    nr_free_pages 177041
Node 0, zone   Normal
    nr_free_pages 16148

That 16148 pages for ZONE_NORMAL is obviously bogus compared to what
buddyinfo is saying.

Commit d1ce749a0d did mess with NR_FREE_PAGES accounting quite a bit.
Guess I'll try a revert and see where I end up.

--
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>

  reply	other threads:[~2012-11-17 23:08 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <bug-50181-27@https.bugzilla.kernel.org/>
2012-11-13 22:03 ` [Bug 50181] New: Memory usage doubles after more then 20 hours of uptime Andrew Morton
2012-11-13 23:04   ` Milos Jakovljevic
2012-11-15 14:05   ` Milos Jakovljevic
2012-11-15 22:12     ` Andrew Morton
2012-11-15 23:11       ` Milos Jakovljevic
2012-11-16 18:34         ` Dave Hansen
2012-11-16 18:46           ` Milos Jakovljevic
2012-11-16 19:15           ` Andrew Morton
2012-11-16 23:59             ` Dave Hansen
2012-11-17 23:08               ` Dave Hansen [this message]
2012-11-19 16:44               ` Dave Hansen
2012-11-16  2:51       ` Dave Hansen

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=50A81900.8000801@linux.vnet.ibm.com \
    --to=dave@linux.vnet.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=b.zolnierkie@samsung.com \
    --cc=bugzilla-daemon@bugzilla.kernel.org \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-mm@kvack.org \
    --cc=sukijaki@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.