linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: ebiederm+eric@ccr.net (Eric W. Biederman)
To: Hans Eric Sandstrom <hes@xinit.se>
Cc: linux-mm@kvack.org
Subject: Re: Alpha quality write out daemon
Date: 14 Jan 1999 10:49:05 -0600	[thread overview]
Message-ID: <m1hftt94vy.fsf@flinx.ccr.net> (raw)
In-Reply-To: Hans Eric Sandstrom's message of "Thu, 14 Jan 1999 15:53:54 +0100"

>>>>> "HS" == Hans Eric Sandstrom <hes@xinit.se> writes:

HS> Eric W. Biederman wrote:
>> This patch is agains 2.2.0-pre5.
>> 
>> I have been working and have implemented a daemon that does
>> all swaping out except from shm areas (todo).
>> 
>> It is intended as an early protype for 2.3.
>> But it's acting like a bug magnet.
>> 
>> What it does is add an extra kernel daemon that does nothing but
>> walking through the page tables start I/O on dirty pages and mark them
>> clean and write protected.  Sleep 30 seconds and do it again.
>> 
>> Since aging isn't taken into account, and because it writes all
>> dirty pages this code is much more aggressive than any variation of
>> our current code in writing swap pages out.
>> 

HS> Can you explain this a little, why mark the pages write protected?

I am making a distinct difference between what our daemons do.
pgflush only writes out data, it never frees memory.
kswapd only frees memory it never writes anything out.

This should be useful for tuning.

The specific selection of write protection is that the
current vm assumes that if a page is in the swap cache,
it is not dirty, and that it is write protected.

To get write access it needs to either copy the page, or tear
down the swap cache.

Currently something is failing to obey this rule but I don't know where.

There is a small race (wrt data intgrity) that the setting of write protection
should be before we can start any I/O on the page.  (So if we write to the page
while it is undergoing I/O, and don't output those bytes we might miss it).

But that has nothing to do with the swapping problem :(

HS> And, this daemon shuld probably try to avoid IO if the system is IO bound already.

Agreed.  But that is a tunining issue.  I don't plan to tackle that until
the code stops blowing up in my face.   However avoiding I/O when the
system is IO bound is very difficult, because at this point we can't detect it.


Eric


--
This is a majordomo managed list.  To unsubscribe, send a message with
the body 'unsubscribe linux-mm me@address' to: majordomo@kvack.org

  parent reply	other threads:[~1999-01-14 18:44 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-01-14 10:08 Eric W. Biederman
     [not found] ` <369E0501.987D2B3B@xinit.se>
1999-01-14 16:49   ` Eric W. Biederman [this message]
1999-01-15  7:31 ` Eric W. Biederman
1998-01-14 18:44   ` Hans Eric Sandström
1999-01-15  9:02     ` Eric W. Biederman
1999-01-17  6:12       ` Beta " Eric W. Biederman
1999-01-18  5:05         ` Eric W. Biederman
1999-01-19 15:15 ` Alpha " Stephen C. Tweedie
1999-01-20 14:52   ` Eric W. Biederman
1999-01-20 18:46     ` Zlatko Calusic
1999-01-25  1:40       ` Eric W. Biederman

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=m1hftt94vy.fsf@flinx.ccr.net \
    --to=ebiederm+eric@ccr.net \
    --cc=hes@xinit.se \
    --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