[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [dm-devel] Simulating faulty disk



On 10/21/2011 03:47 PM, Yathindra wrote:
dmsetup create d0 --table="0 `blockdev --getsize /dev/sdb` delay
/dev/sdb 0 500"
dmsetup create f0 --table="0 `blockdev --getsize /dev/mapper/d0` flakey
/dev/mapper/d0 0 9 1"
mkfs -t ext3 /dev/mapper/f0
...
...
ext2fs_mkdir: Attempt to read block from filesystem resulted in short
read while creating root dir

Can we even mount such a device ?

It's a flakey device :)

With that table you'll have a device that is failing write I/Os for 1s in every ten. If that coincides with mkfs trying to write to the device it will create a corrupted file system.

Depending on what you are trying to test you may want to put data on the device first.

Regards,
Bryn.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]