Re: moving spares into group and checking spares

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Sep 14 2016, scar wrote:

> i currently have four RAID-5 md arrays which i concatenated into one 
> logical volume (lvm2), essentially creating a RAID-50.  each md array 
> was created with one spare disk.
>
> instead, i would like to move the four spare disks into one group that 
> each of the four arrays can have access to when needed.  i was wondering 
> how to safely accomplish this, preferably without unmounting/disrupting 
> the filesystem.

You don't need to move the devices.  Just use the spare-group= setting
in mdadm.conf to tell mdadm that all arrays should be considered part of
the same spare-group.  Then "mdadm --monitor" will freely move spares
between arrays as needed.

>
> secondly, i have the checkarray script scheduled via cron to 
> periodically check each of the four arrays.  i noticed in the output of 
> checkarray that it doesn't list the spare disk(s).  so i'm guessing they 
> are not being checked?  i was wondering, then, how i could also check 
> the spare disks to make sure they are healthy and ready to be used if 
> needed?

mdadm doesn't provide any automatic support for this.
You would need to e.g.
 - remove a spare from an array
 - test it in some way: e.g. use dd to read every block.
 - if satisfied, add it back to the array.

NeilBrown

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux