Re: migrating raid-1 to different drive geometry ?

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

 




I'd missed the mdadm --grow feature as well, so I checked into it.

It is only capable of increasing size on raid5, not component count. The specific use case used as an example is that you slowly retire component drives and the replacements are larger. When all components are the larger size, you can grow the raid5 array to use the full size of the device, followed by a filesystem expansion to use the grown array.

That makes sense, given the disk layout of raid5 - its not hard to add more stripes on the end of components, but adding new components requires each stripe to change significantly.

To grow component count on raid5 you have to use raidreconf, which can work, but will toast the array if anything goes bad. I have personally had it work, and not work, in different instances. The failures were not necessarily raidreconf's fault, but its not fault tolerant is the point, as it starts at the first stripe, laying things out the new way, and if it doesn't finish, and finish correctly, you are in an irretrievable inconsistent state.

raid1 can grow components with mdadm --grow though.

Cool trick

-Mike

Robin Bowes wrote:
Neil Brown wrote:

If you are using a recent 2.6 kernel and mdadm 1.8.0, you can grow the
array with
   mdadm --grow /dev/mdX --size=max


Neil,

Is this just for RAID1? OR will it work for RAID5 too?

R.
-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[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