From: Jason Li <zhjl000@yahoo.com>
To: linux-kernel@vger.kernel.org
Subject: out_of_memory called to often
Date: Tue, 11 Mar 2003 11:13:42 -0800 (PST) [thread overview]
Message-ID: <20030311191342.18575.qmail@web41003.mail.yahoo.com> (raw)
Hi,
We are running an embedded linux (2.4.19) with no swap
sapce. And we haven't applied any rmap yet.
Currely when the system runs low (reached the
pages_low water-mark), kswapd kicks in. But soon after
kswapd kicks in, the out_of_memory is called due to
swapd not being able to reclaim enough pages from the
page cache from each run of it. I don't understand why
sometimes swapd can't reclaim the SWAP_CLUSTER_MAX
number of pages.
We know there are still some number of cache pages
that can be reclaimed if we run the following c
program:
int main() {
int i, j;
char *tmp[10000]
for (i=0; i<NUMBER_OF_PAGES_LEFT_BEFORE_pages_low;
i++) tmp[i]=malloc(4k);
for (i=0; i<NUMBER_OF_PAGES_LEFT_BEFORE_pages_low;
i++) free(tmp[i]);
}
To solve this problem, I am trying to make a
conditional call to the out_of_memory() -- only if the
pages_min is reached, then the out_of_memory() can be
called.
If we can solve the swapd livelock problem, is this a
feasible solution? If you have a better idea, can you
please share with us?
Any input will be greatly appreciated.
Thanks very much in advance! Please include my email
address in your reply.
-Jason
__________________________________________________
Do you Yahoo!?
Yahoo! Web Hosting - establish your business online
http://webhosting.yahoo.com
next reply other threads:[~2003-03-11 19:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-03-11 19:13 Jason Li [this message]
2003-03-11 20:43 ` Ross Biro
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=20030311191342.18575.qmail@web41003.mail.yahoo.com \
--to=zhjl000@yahoo.com \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®