I have a RAID5 (using motherboard all 6 sata controllers) booting off a usb flash drive. Had Smart monitor and e-mailing setup and am getting smart error e-mail notifications on /dev/sdb1. I can the short smart test on it and it stopped at 90%.
Anyhow I have been playing around in virtual box (Not same system) on how to remove and replace the drive and the following works like a champ for virtualbox
sudo mdadm --detail --scan
sudo mdadm --manage /dev/md0 --fail /dev/sdb1
Then, remove it from the array
Code:
sudo mdadm --manage /dev/md0 --remove /dev/sdb1
Then, replace it with a new one...
Code:
sudo mdadm --manage /dev/md0 --add /dev/sdb1
In VB that works great, array quickly resyncs (only using 250MB x4 VDisks). My setup is slightly different. When I run sudo mdadm --detail /dev/md0 I get
Clean array and drives show as:
/dev/sdb1
/dev/sdc1
/dev/sdd1
/dev/sde
/dev/sdf
/dev/sdg
Now /dev/sdb1 is the faulty smart error drive (others short smart tested passed fine). Can I use the
sudo mdadm --manage /dev/md0 --fail /dev/sdb1
sudo mdadm --manage /dev/md0 --remove /dev/sdb1
Then, replace it with a new one...
sudo mdadm --manage /dev/md0 --add /dev/sdb
Meaning old drive was /dev/sdb1 (originally setup raid5 during os isntall using 3 disks & have added 3 more since)
and new is just /dev/sdb (minus the 1 at the end)
Will that work fine or am I missing a step?
I read somewhere about using fdisk to copy /dev/sdc1 /dev/sdb1 to create the same partition or something like that. Can anyone advise, thanks in advance.
Bookmarks