Linux RAID subsystem development
 help / color / mirror / Atom feed
From: Neil Brown <neilb@cse.unsw.edu.au>
To: rjoseph@kerr.lanl.gov
Cc: linux-raid@vger.kernel.org
Subject: Re: Faulty disk detection code: looking to tweak it for network devices
Date: Tue, 5 Aug 2003 12:36:25 +1000	[thread overview]
Message-ID: <16175.6185.517151.469809@gargle.gargle.HOWL> (raw)
In-Reply-To: message from Ryan P. Joseph on Monday August 4

On Monday August 4, rjoseph@jaw.lanl.gov wrote:
> Hello,
> 
> So, my real question is: where in the blazes does the MD/RAID system actually,
> really, seriously detect a failed disk?!  And when it does this, what is the
> path of function calls taken to say "hey, this disk is failed, don't use it!"?

(talk 2.4 language here)
When raid5 want to schedule I/O on a block, it (Among other things)
sets  b_end_io to either raid5_end_read_request or
raid5_end_write_request depending on type of request, and then calls
generic_make_request to submit the request.

When the request completes, the b_end_io function will be called.  The
second argument to the function ("uptodate") is '1' if the request was
successful, and '0' if it failed (no further details of failure mode,
sorry).

If uptodate== 0, md_error is called which marks the device as faulty
and calls raid5_error which marks it faulty again....

Eventually handle_stripe() gets called on the stripe again.  It
notices that the data still needs to be read or written, but now that
device is failed so it uses some other strategy to accomplish the
desired gaol.

Let me know if you need anything else clarified.

NeilBrown

      reply	other threads:[~2003-08-05  2:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-08-04 22:27 Faulty disk detection code: looking to tweak it for network devices Ryan P. Joseph
2003-08-05  2:36 ` Neil Brown [this message]

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=16175.6185.517151.469809@gargle.gargle.HOWL \
    --to=neilb@cse.unsw.edu.au \
    --cc=linux-raid@vger.kernel.org \
    --cc=rjoseph@kerr.lanl.gov \
    /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