Thread (5 messages) 5 messages, 3 authors, 2014-12-12

Re: Growing RAID-10 (near-2) array - which kernel needed?

From: NeilBrown <hidden>
Date: 2014-12-11 20:28:14

On Thu, 11 Dec 2014 19:21:39 +0000 Robin Hill [off-list ref] wrote:
On Thu Dec 11, 2014 at 07:31:31PM +0100, cvb@kruemel.org wrote:
quoted
Apologies for raising this topic again, but I can't seem to find 
anything googling, and man mdadm doesn't also give me a clue. Which 
kernel version is needed to grow a near-2 RAID 10 array?
Full reshape support (changing number of devices, layout or chunk size)
was introduced in 3.5 (http://kernelnewbies.org/Linux_3.5).
quoted
I'm currently running kernel 3.13.0 with mdadm 3.2.5. But I could also 
use a live CD with a newer kernel, if needed.
It also requires mdadm 3.3 or above.
quoted
I have replaced the 4 disks here with larger ones (2TB drives -> 4 TB 
drives), and this is what the array currently looks like:

# mdadm --detail /dev/md0
/dev/md0:
         Version : 1.2
   Creation Time : Sat Aug 20 08:15:07 2011
      Raid Level : raid10
      Array Size : 3906764800 (3725.78 GiB 4000.53 GB)
   Used Dev Size : 1953382400 (1862.89 GiB 2000.26 GB)
    Raid Devices : 4
   Total Devices : 4
     Persistence : Superblock is persistent

     Update Time : Thu Dec 11 08:31:15 2014
           State : clean
  Active Devices : 4
Working Devices : 4
  Failed Devices : 0
   Spare Devices : 0

          Layout : near=2
      Chunk Size : 512K

            Name : alpha:0  (local to host alpha)
            UUID : 8199e640:58fc3a04:99b52fe6:80a1574d
          Events : 918971

     Number   Major   Minor   RaidDevice State
        6       8        1        0      active sync   /dev/sda1
        5       8       33        1      active sync   /dev/sdc1
        7       8       17        2      active sync   /dev/sdb1
        4       8       49        3      active sync   /dev/sdd1
I can't find anything explicitly covering growing a RAID 10 by just
increasing the device sizes. 
commit 006a09a0ae0a494473a8cd82c8d1d653e37e6663
Author: NeilBrown [off-list ref]
Date:   Mon Mar 19 12:46:40 2012 +1100

    md/raid10 - support resizing some RAID10 arrays.


$ git describe --contains 006a09a0ae0a494473a8cd82c8d1d653e37e6663
v3.4-rc1~147^2~8

So Linux-3.4 is needed.
I don't think you need a particularly new mdadm.

NeilBrown
                             I would have thought that would be an
easier task than doing so by adding disks, so should be supported in an
earlier version. mdadm 3.2.1 mentions supporting converting between
RAID-10 and RAID-1, which can definitely be grown.

Have you tried doing a grow with the versions you have?

Cheers,
    Robin
  

Attachments

  • (unnamed) [application/pgp-signature] 811 bytes
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help