4

I'm getting the following mail every day on a server:

This is an automatically generated mail message from mdadm
running on <host>

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 : [raid1]
md0 : active raid1 sda1[0] sdb1[1]
      731592000 blocks [2/2] [UU]

unused devices: <none>

The output from cat /proc/mdstat looks fine though, so it's not obvious what is causing this problem.

7

The cause was an erroneous spares=1 option in the mdadm.conf:

# definitions of existing MD arrays
ARRAY /dev/md0 UUID=621d5f15:cce75825:60273c48:78a7dac7
   spares=1

I'm not sure how this ended up there, but I suppose it happened when a device failed and was replaced.

Removing the spares=1 option or just recreating the mdadm.conf from scratch fixes the problem:

/usr/share/mdadm/mkconf > /etc/mdadm/mdadm.conf
1

I got the message, however I have a spare disk. The answer above puzzled me a little. The resolution appeared to be simple.

There was spares=2 in my mdadm.conf. The odd thing is - I haven't configured that. It must have been done by some installation script. I have two RAIDs with one spare each. The first one got properly "spares=1" and the second one spares=2.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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