0

So I changed my case and I don't know why but one my SATA port does not work anymore. So only 5 of my 6 RAID5 disks were recognized. The volume was automounted anyway and I already wrote new files on it. So I shut-downed the computer and just used the other free SATA port, but unfortunately mdadm didn't picked it as my 6th disk.
It just counts my disk as removed even though the system recognized it as device sdd. I saw a readd command in the man page of mdadm but I don't know if it's appropriate for my case. I don't want to make a stupid mistake. How can I restore the volume to 6 active disks?

Additional information about my raid5 volume :

root@Debian8:~# mdadm --detail /dev/md127

Persistence : Superblock is persistent  
Update Time : Mon May 23 21:24:10 2016  
      State : clean, degraded


       Name : openmediavault:RAID5en6x6
       UUID : 016ab622:4c52176d:33c85eea:9226dd9e
     Events : 13571

Number   Major   Minor   RaidDevice State
   0       8        0        0      active sync   /dev/sda
   2       0        0        2      removed
   2       8       16        2      active sync   /dev/sdb
   3       8       64        3      active sync   /dev/sde
   4       8       32        4      active sync   /dev/sdc
   5       8       80        5      active sync   /dev/sdf
0

So, after a long read of the manual I tried this command :

 mdadm --manage /dev/md127 -t -a /dev/sdd

-a for add as mdadm is supposed to reconized the recently removed disk and if it doesn't, it adds the disk as spare.
-t was supposed to be for test but from the look of the detail of my array mdadm is currently "rebuilding" and it's going to take a long time :

Rebuild Status : 0% complete

       Name : openmediavault:RAID5en6x6
       UUID : 016ab622:4c52176d:33c85eea:9226dd9e
     Events : 13583

Number   Major   Minor   RaidDevice State
   0       8        0        0      active sync   /dev/sda
   6       8       48        1      spare rebuilding   /dev/sdd
   2       8       16        2      active sync   /dev/sdb
   3       8       64        3      active sync   /dev/sde
   4       8       32        4      active sync   /dev/sdc
   5       8       80        5      active sync   /dev/sdf

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.