From: "Bryn M. Reeves" <bmr@redhat.com>
To: Yathindra <ydev@cs.utah.edu>
Cc: linux-scsi@vger.kernel.org
Subject: Re: Simulating faulty disk
Date: Thu, 20 Oct 2011 16:56:25 +0100 [thread overview]
Message-ID: <4EA044A9.6070406@redhat.com> (raw)
In-Reply-To: <4EA04201.1050702@cs.utah.edu>
On 10/20/2011 04:45 PM, Yathindra wrote:
> Hi Bryn,
>
> Thanks for that info. Could you please tell me where I can find more
> details about using it.
>
> Thanks again,
> Yathi
There's a couple of brief files describing the targets in the
Documentation/device-mapper directory:
http://www.kernel.org/doc/Documentation/device-mapper/dm-flakey.txt
http://www.kernel.org/doc/Documentation/device-mapper/delay.txt
They both work like the linear target (except that they introduce the
specified faults according to their parameters).
To set up a device with both you'd need to use a pair of stacked devices
so something like:
dmsetup create d0 --table="0 $SECTORS delay $DEVICE 0 500"
dmsetup create f0 --table="0 $SECTORS flakey /dev/mapper/d0 0 9 1"
This will create a device /dev/mapper/f0 that is drops out for 1s in
every 10 and has a 500ms delay on reads and writes. SECTORS is the size
of the underlying device in sectors (use e.g. $(blockdev --getsize)).
You can optionally specify separate delays/device for writes to the
delay layer and write loss / write corruption for the flakey layer - see
the doc files and also the comments above flakey_ctr and delay_ctr for
more details.
Regards,
Bryn.
next prev parent reply other threads:[~2011-10-20 15:56 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-20 3:18 Simulating faulty disk Yathindra
[not found] ` <20111020044734.GC15211@atlantis.cc.ndsu.nodak.edu>
2011-10-20 7:30 ` Yathindra
2011-10-20 8:43 ` Yathindra
2011-10-20 9:27 ` Bryn M. Reeves
2011-10-20 15:45 ` Yathindra
2011-10-20 15:56 ` Bryn M. Reeves [this message]
2011-10-20 15:59 ` Yathindra
2011-10-20 16:46 ` Yathindra
2011-10-20 17:40 ` Bryn M. Reeves
2011-10-20 17:53 ` Yathindra
[not found] ` <4EA13A52.60902@redhat.com>
[not found] ` <4EA18610.3050900@cs.utah.edu>
2011-10-21 14:56 ` Bryn M. Reeves
2011-10-21 15:00 ` Yathindra
2011-10-21 15:13 ` Yathindra
2011-10-21 15:21 ` Bryn M. Reeves
2011-10-21 16:33 ` Yathindra
2011-10-22 6:16 ` Yathindra
2011-10-21 4:14 ` Yathindra
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=4EA044A9.6070406@redhat.com \
--to=bmr@redhat.com \
--cc=linux-scsi@vger.kernel.org \
--cc=ydev@cs.utah.edu \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.