fixing the raid

I noticed a couple weeks ago that I kept getting errors in the logs for one of the disks in the multimedia array. This was upsetting, but since I had paid a little more for these disks to get the 5 year warranty, I wasn't too concerned. Then I did a warranty check on the disk. It was the disk that WD sent me to replace the last disk that failed.

Oh goody.

After futzing with the WD support website, they had changed it since the last time I had to RMA a disk, I finally got an advance RMA setup. The disk arrived last week, but I was unable, until today, to get around to replacing it.

So I powered down the server, pulled the bad disk ( installed 2011-04-20 according to the label I put on it ) and put the new one in it's place. Then I rebooted. The system complained about a degraded array, was I sure I wanted to continue, even though I hit 'y', it dropped to a minimal recovery shell. sigh

Reboot, let's try this again. Same thing.

dirty words

Reboot again, hit 'e' to edit the boot paramemeters in GRUB, add 'bootdegraded=true' and voila, it boots.

Now to it was as simple as:
Copy the partition map from the existing drive...

# sfdisk -d /dev/sde | sfdisk/dev/sda

Add the new disk into the array:

# mdadm --manage /dev/md127 --add /dev/sda1

And check on the progress:

 # cat /proc/mdstat 
 Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5]
 [raid4] [raid10] 
 md127 : active raid1 sda1[2] sde1[0]
       1953511936 blocks [2/1] [U_]
       [>....................]  recovery =  3.8% (75987264/1953511936) finish=218.8min speed=142988K/sec

unused devices: <none>

Not too shabby!

# df -kh /multimedia/
Filesystem                    Size  Used Avail Use% Mounted on
/dev/mapper/raid--lvm-movies  1.8T  841G  882G  49% /multimedia

Now I just need to get the old drive back into the shipping box and get it back to WD so they don't charge me $220 for the replacement disk.