I want to understand and if it makes sense, disable the alert message I receive about spares missing on my ubuntu linux software raid 5.

I used mdadm and set up a /dev/md0 raid volume made up of 3 hard drives.

I then set up email alerts so I can see when there is a problem with it.

I often get these 'spare missing' alerts, and I assume that means there is a second spare defined and I do not have one.

I am looking to clarify that this is actually not really a problem, and that I can change a setting to tell mdadm I do not have a second spare (I have only 3 drives). My system should continue running if 1 drive goes down?

Here is the alert message:

This is an automatically generated mail message from mdadm running on myserver

A SparesMissing event had been detected on md device /dev/md0.

Faithfully yours, etc.

P.S. The /proc/mdstat file currently contains the following:

Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10] md0 : active raid5 sdc1[1] sdb1[0] sdd1[2]
      1953519488 blocks level 5, 64k chunk, algorithm 2 [3/3] [UUU]

unused devices: <none>
link|improve this question

59% accept rate
How is the group defined in mdadm.conf? – Shane Madden Sep 6 '11 at 16:13
DEVICE partitions ARRAY /dev/md0 level=raid5 num-devices=3 spares=1 UUID=80c8bec2:d8660d29:ae8962f 2:b7b9c495 , so I assume spares=0 would fix it, but is there a negative to this? A spare is optional, correct? Raid 5 means if 1 drive goes down the other 2 will keep running, correct? – Scott Szretter Sep 6 '11 at 17:04
So is it safe to set it to spares=0 ? – Scott Szretter Sep 9 '11 at 12:03
feedback

1 Answer

up vote 0 down vote accepted

Yes, set to 0 spares; a RAID 5 group will be able to tolerate 1 failure of an active disk. A spare is used as a reserved disk to immediately start rebuilding the array if one of the active disks dies.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.