Skip to contentSkip to conversation

mke2fs with discard option breaks RAID5 array

DISCUSSION Martin Wilck 2 participants 2 messages Sep 14, 2013 – Sep 23, 2013 MD RAID

lore
Share & tools
lore
#0 lore raw

I just had the following weird effect under OpenSUSE 12.3, kernel 3.7.10-1.16. I am wondering if it's a known problem.

Creating a RAID5 array (format doesn't seem to matter) either with the openSUSE native mdadm 3.2.6 or mdadm 3.3, and running mke2fs on it, fails. The RAID array is broken after that, all disks faulty, any IO fails.

Further examination shows that the problem is related to mke2fs trying to discard blocks. Running "-E nodiscard" or setting "discard=no" in mke2fs.conf fixes the problem. Unfortnately, "discard" seems to be the default.

Details under https://bugzilla.novell.com/show_bug.cgi?id=840413

Has anyone seen this before?
Martin

#1 lore raw
Quoted 7 lines · Martin Wilck

I just had the following weird effect under OpenSUSE 12.3, kernel 3.7.10-1.16. I am wondering if it's a known problem.

Creating a RAID5 array (format doesn't seem to matter) either with the openSUSE native mdadm 3.2.6 or mdadm 3.3, and running mke2fs on it, fails. The RAID array is broken after that, all disks faulty, any IO fails.

Quoted 8 lines

Further examination shows that the problem is related to mke2fs trying to discard blocks. Running "-E nodiscard" or setting "discard=no" in mke2fs.conf fixes the problem. Unfortnately, "discard" seems to be the default.

Details under https://bugzilla.novell.com/show_bug.cgi?id=840413

Has anyone seen this before?

This sounds like the issue addressed by:

66c28f9 [SCSI] sd: Update WRITE SAME heuristics
5026d7a md/raid1,5,10: Disable WRITE SAME until a recovery strategy is in place