Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1456380
| From | Mel Gorman <mgorman@techsingularity.net> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [bug, 4.8] /proc/meminfo: counter values are very wrong |
| Date | 2016-08-04 14:40 +0200 |
| Message-ID | <s2q6m-DV-49@gated-at.bofh.it> (permalink) |
| References | <s2jey-4wK-21@gated-at.bofh.it> <s2q6m-DV-39@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Thu, Aug 04, 2016 at 01:24:09PM +0100, Mel Gorman wrote: > On Thu, Aug 04, 2016 at 03:10:51PM +1000, Dave Chinner wrote: > > Hi folks, > > > > I just noticed a whacky memory usage profile when running some basic > > IO tests on a current 4.8 tree. It looked like there was a massive > > memory leak from my monitoring graphs - doing buffered IO was > > causing huge amounts of memory to be considered used, but the cache > > size was not increasing. > > > > Looking at /proc/meminfo: > > > > $ cat /proc/meminfo > > MemTotal: 16395408 kB > > MemFree: 79424 kB > > MemAvailable: 2497240 kB > > Buffers: 4372 kB > > Cached: 558744 kB > > SwapCached: 48 kB > > Active: 2127212 kB > > Inactive: 100400 kB > > Active(anon): 25348 kB > > Inactive(anon): 79424 kB > > Active(file): 2101864 kB > > Inactive(file): 20976 kB > > Unevictable: 13612980 kB <<<<<<<<< > > This? Very quickly done, no boot testing > Or better yet, this. This is aimed at the proc reporting only. diff --git a/fs/proc/meminfo.c b/fs/proc/meminfo.c index 09e18fdf61e5..b9a8c813e5e6 100644 --- a/fs/proc/meminfo.c +++ b/fs/proc/meminfo.c @@ -46,7 +46,7 @@ static int meminfo_proc_show(struct seq_file *m, void *v) cached = 0; for (lru = LRU_BASE; lru < NR_LRU_LISTS; lru++) - pages[lru] = global_page_state(NR_LRU_BASE + lru); + pages[lru] = global_node_page_state(NR_LRU_BASE + lru); available = si_mem_available(); diff --git a/mm/page_alloc.c b/mm/page_alloc.c index fb975cec3518..baa97da3687d 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -4064,7 +4064,7 @@ long si_mem_available(void) int lru; for (lru = LRU_BASE; lru < NR_LRU_LISTS; lru++) - pages[lru] = global_page_state(NR_LRU_BASE + lru); + pages[lru] = global_node_page_state(NR_LRU_BASE + lru); for_each_zone(zone) wmark_low += zone->watermark[WMARK_LOW]; -- Mel Gorman SUSE Labs
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[bug, 4.8] /proc/meminfo: counter values are very wrong Dave Chinner <david@fromorbit.com> - 2016-08-04 07:20 +0200
Re: [bug, 4.8] /proc/meminfo: counter values are very wrong Mel Gorman <mgorman@techsingularity.net> - 2016-08-04 14:40 +0200
Re: [bug, 4.8] /proc/meminfo: counter values are very wrong Mel Gorman <mgorman@techsingularity.net> - 2016-08-04 14:40 +0200
Re: [bug, 4.8] /proc/meminfo: counter values are very wrong Dave Chinner <david@fromorbit.com> - 2016-08-05 01:20 +0200
Re: [bug, 4.8] /proc/meminfo: counter values are very wrong Mel Gorman <mgorman@techsingularity.net> - 2016-08-05 13:10 +0200
Re: [bug, 4.8] /proc/meminfo: counter values are very wrong Dave Chinner <david@fromorbit.com> - 2016-08-05 14:00 +0200
Re: [bug, 4.8] /proc/meminfo: counter values are very wrong Dave Chinner <david@fromorbit.com> - 2016-08-05 14:10 +0200
csiph-web