Re: /proc/sys/vm/swappiness == 0 makes OOM killer go beserk
From: Denis Vlasenko
Date: Sat Jan 14 2006 - 10:44:41 EST
On Saturday 14 January 2006 15:53, Jim MacBaine wrote:
> On 1/14/06, Nick Craig-Wood <nick@xxxxxxxxxxxxxx> wrote:
>
> > On my home workstation I do a lot of stuff with very large video
> > files, so set swappiness to 0 some time ago so using these large files
> > would stop all the applications getting pushed out into swap.
>
> My motivation was similar: My desktop usually runs 24 hrs and I leave
> large applications which I use from time to time always open. Like
> OpenOffice, Firefox, Emacs with large buffers, etc. In the night, the
> machine performs two disk-intensive tasks. First a backup then
> updatedb. And every morning about 650 MB of 1 GB RAM is used for
> caches and all my application need to be swapped in before I can use
> them.
>
> Of course, the increase of disk cache is reasonable for those tasks,
> but honestly, I don't care whether the updatedb process takes 10 or 20
> minutes in the night. But I do care if switching between applications
> needs >10 seconds in the morning.
>
> Would it be possible to trigger paging in specific applications from
> userspace? So I might run something like
>
> echo -n firefox-bin > /proc/sys/vm/page-in
> echo -n soffice-bin > /proc/sys/vm/page-in
> ...
Crude, but may work:
swapoff -a
swapon -a
> after my nightly cron jobs have filled the memory with disk cache data
> that won't be useful anymore, because in my daily work I rarely touch
> 10% of the filesystem.
--
vda
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/