mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steve Lord <lord@sgi.com>
To: Roy Sigurd Karlsbakk <roy@karlsbakk.net>
Cc: Mark Hahn <hahn@physics.mcmaster.ca>, linux-kernel@vger.kernel.org
Subject: Re: possible bug with RAID
Date: 11 Dec 2001 13:34:03 -0600	[thread overview]
Message-ID: <1008099243.17996.13.camel@jen.americas.sgi.com> (raw)
In-Reply-To: <Pine.LNX.4.30.0112111952430.1232-100000@mustard.heime.net>
In-Reply-To: <Pine.LNX.4.30.0112111952430.1232-100000@mustard.heime.net>

[-- Attachment #1: Type: text/plain, Size: 746 bytes --]

On Tue, 2001-12-11 at 12:54, Roy Sigurd Karlsbakk wrote:
> > it would be interesting to write a simple benchmark
> > that simply reads a file at a fixed rate.  *that* would
> > actually simulate your app.
> 
> sure. I'm using tux+wget for that. I were just playing around with dd
> 
> > sounds like a VM/balance problem.  you didn't mention which kernel
> > you're using.
> 
> 2.4.16 w/tux + xfs. The fs used on the raid vol is xfs

We just got to the bottom of a problem in xfs which was causing memory
not to get cleaned as efficiently as it should be - it lead to dbench
lockups on low memory systems. It is possible you are seeing a similar
effect - we dirty all the memory and then struggle to clean it up.

Try the attached patch.

Steve



[-- Attachment #2: xfs.patch --]
[-- Type: text/plain, Size: 1671 bytes --]


===========================================================================
Index: linux/fs/buffer.c
===========================================================================

--- /usr/tmp/TmpDir.12499-0/linux/fs/buffer.c_1.96	Tue Dec 11 13:33:26 2001
+++ linux/fs/buffer.c	Tue Dec 11 13:31:17 2001
@@ -224,6 +224,7 @@
 	unlock_buffer(bh);
 	put_bh(bh);
 }
+EXPORT_SYMBOL(end_buffer_io_sync);
 
 /*
  * The buffers have been marked clean and locked.  Just submit the dang
@@ -2538,7 +2539,7 @@
 /*
  * Can the buffer be thrown out?
  */
-#define BUFFER_BUSY_BITS	((1<<BH_Dirty) | (1<<BH_Lock))
+#define BUFFER_BUSY_BITS	((1<<BH_Dirty) | (1<<BH_Lock) | (1<<BH_Delay))
 #define buffer_busy(bh)		(atomic_read(&(bh)->b_count) | ((bh)->b_state & BUFFER_BUSY_BITS))
 
 /*

===========================================================================
Index: linux/fs/pagebuf/page_buf_io.c
===========================================================================

--- /usr/tmp/TmpDir.12499-0/linux/fs/pagebuf/page_buf_io.c_1.102	Tue Dec 11 13:33:26 2001
+++ linux/fs/pagebuf/page_buf_io.c	Tue Dec 11 10:22:58 2001
@@ -1337,10 +1337,12 @@
 	head = bh;
 	do {
 		lock_buffer(bh);
-		set_buffer_async_io(bh);
-		set_bit(BH_Uptodate, &bh->b_state);
-		clear_bit(BH_Dirty, &bh->b_state);
 		clear_bit(BH_Delay, &bh->b_state);
+		if (atomic_set_buffer_clean(bh)) {
+			get_bh(bh);
+			bh->b_end_io = end_buffer_io_sync;
+			refile_buffer(bh);
+		}
 		bh = bh->b_this_page;
 	} while (bh != head);
 
@@ -1350,6 +1352,7 @@
 	} while (bh != head);
 
 	SetPageUptodate(page);
+	UnlockPage(page);
 	page_cache_release(page);
 }
 

  reply	other threads:[~2001-12-11 19:35 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <Pine.LNX.4.33.0112111347330.7710-100000@coffee.psychology.mcmaster.ca>
2001-12-11 18:54 ` Roy Sigurd Karlsbakk
2001-12-11 19:34   ` Steve Lord [this message]
2001-12-11 21:18   ` Steve Lord
2001-12-11 18:33 Roy Sigurd Karlsbakk

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=1008099243.17996.13.camel@jen.americas.sgi.com \
    --to=lord@sgi.com \
    --cc=hahn@physics.mcmaster.ca \
    --cc=linux-kernel@vger.kernel.org \
    --cc=roy@karlsbakk.net \
    /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®