public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Bill Davidsen <davidsen@tmr.com>
To: lgb@lgb.hu
Cc: linux-kernel@vger.kernel.org
Subject: Re: Kernel cached memory
Date: Mon, 01 Aug 2005 17:08:56 -0400	[thread overview]
Message-ID: <42EE8F68.4050107@tmr.com> (raw)
In-Reply-To: <20050801103835.GE28346@vega.lgb.hu>

Gábor Lénárt wrote:

>On Mon, Jul 25, 2005 at 12:47:50PM -0400, Bill Davidsen wrote:
>  
>
>>Gábor Lénárt wrote:
>>    
>>
>>>On Fri, Jul 22, 2005 at 05:46:58PM +0800, Ashley wrote:
>>>
>>>      
>>>
>>>> I've a server with 2 Operton 64bit CPU and 12G memory, and this server 
>>>>is used to run  applications which will comsume huge memory,
>>>>the problem is: when this aplications exits,  the free memory of the 
>>>>server is still very low(accroding to the output of "top"), and
>>>>        
>>>>
>>>>from the output of command "free", I can see that many GB memory was 
>>>      
>>>
>>>>cached by kernel. Does anyone know how to free the kernel cached
>>>>memory? thanks in advance.
>>>>        
>>>>
>>>It's a very - very - very old and bad logic (at least nowdays) from the
>>>stone age to free up memory.
>>>      
>>>
>>It's very Microsoft to claim that the OS always knows best, and not let 
>>the user tune the system the way they want it tuned. And if that means 
>>to leave a bunch of free memory for absolute fastest availability, the 
>>admin should have that option.
>>    
>>
>
>Sure, sorry if my comment can be treated in this way ... I mean surprising
>amount of people I've met criticised Linux (well, some years ago when DOS
>was popular) that he/she want to see that 'free memory' field reported eg by
>'top' should be the maximum all the time ... I mean this way: this is the
>behaviour which is quite wrong, I've written about this.
>
>Sure, because of my not too good English, I may have missed the real meaning
>of the mail, sorry about it!
>
Well, I thought I understood "from the stone age" but I may have taken 
it slightly too literally. But I really would like to have more control 
over Linux memory use, because it does cause bad behaviour at times. If 
I have 4GB of RAM, I'd like to set 200MB or so aside for programs, and 
never page out the window I'm going to uncover later. Likewise when I 
write a DVD image, I would like to avoid buffering a few GB without i/o 
and then driving the disk totally busy while it gets written out (after 
it has pushed out things I will use again).

The old 2.4.x-aa kernels had some tunables to make the kernel aggressive 
about writing pages to disk quickly, and I haven't been able to match 
that behaviour without patches in 2.6. I may be missing a tunable, but 
swappiness doesn't seem to be the one I want. I have a patch I'm playing 
with, but it's not ready for prime time, and is probably counter to the 
current philosophy of memory management.

Thanks for clarifying.

-- 
bill davidsen <davidsen@tmr.com>
  CTO TMR Associates, Inc
  Doing interesting things with small computers since 1979


  reply	other threads:[~2005-08-01 21:03 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-22  9:46 Kernel cached memory Ashley
2005-07-22 11:31 ` Diego Calleja
2005-07-22 12:57 ` Erik Mouw
2005-07-22 21:43   ` John Pearson
2005-07-23 12:31     ` Denis Vlasenko
2005-07-22 13:25 ` Gábor Lénárt
2005-07-22 17:58   ` Lee Revell
2005-07-23 10:50     ` Oliver Neukum
2005-07-25 16:47   ` Bill Davidsen
2005-07-25 17:03     ` Diego Calleja
2005-07-25 17:07     ` Paolo Ornati
2005-07-25 18:02       ` Bill Davidsen
2005-08-01 10:38     ` Gábor Lénárt
2005-08-01 21:08       ` Bill Davidsen [this message]
  -- strict thread matches above, loose matches on Subject: below --
2005-07-26  0:35 Chuck Ebbert
     [not found] <4t5s8-68A-33@gated-at.bofh.it>
     [not found] ` <4tdIU-479-9@gated-at.bofh.it>
2005-07-26  5:03   ` Robert Hancock
2005-07-26 15:00     ` Bill Davidsen

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=42EE8F68.4050107@tmr.com \
    --to=davidsen@tmr.com \
    --cc=lgb@lgb.hu \
    --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