From: Larry Woodman <lwoodman@redhat.com>
To: linux-mm@kvack.org
Subject: [PATCH] Include count of pagecache pages in show_mem() output.
Date: Fri, 04 Jan 2008 07:43:21 -0500 [thread overview]
Message-ID: <1199450601.17215.2.camel@dhcp83-56.boston.redhat.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 677 bytes --]
The show_mem() output does not include the total number of
pagecache pages. This really limits the value of the debugging
information sent to the console and /var/log/messages file when OOM
kills occur.
The attached patch includes the total pagecache pages in that output:
-------------------------------------------------
Node 0 Normal: empty
Node 0 HighMem: empty
> >>113032 pagecache pages
Swap cache: add 0, delete 0, find 0/0, race 0+0
Free swap = 2031608kB
Total swap = 2031608kB
Free swap: 2031608kB
523900 pages of RAM
42142 reserved pages
63864 pages shared
0 pages swap cached
------------------------------------------------
[-- Attachment #2: showmem.patch --]
[-- Type: text/x-patch, Size: 347 bytes --]
--- linux-2.6.18.noarch/mm/page_alloc.c.orig 2008-01-03 15:12:27.000000000 -0500
+++ linux-2.6.18.noarch/mm/page_alloc.c 2008-01-03 15:12:29.000000000 -0500
@@ -1359,6 +1359,8 @@ void show_free_areas(void)
printk("= %lukB\n", K(total));
}
+ printk("%d pagecache pages\n", global_page_state(NR_FILE_PAGES));
+
show_swap_cache_info();
}
reply other threads:[~2008-01-04 12:47 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1199450601.17215.2.camel@dhcp83-56.boston.redhat.com \
--to=lwoodman@redhat.com \
--cc=linux-mm@kvack.org \
/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