Re: [Hampshire] Restoring and expanding a RAID mirror

Top Page

Reply to this message
Author: Paul Tansom
Date:  
To: hampshire
Subject: Re: [Hampshire] Restoring and expanding a RAID mirror
** Andy Smith <andy@???> [2007-04-10 18:05]:
> On Tue, Apr 10, 2007 at 05:54:48PM +0100, Paul Tansom wrote:
> > Unfortunately I can't source a suitable 160G HD to match my existing one
> > (a Maxtor one with 8M cache - I can only get 2M), and given the prices I
> > decided to nab a couple of Seagate 250G drives with 16M cache instead.
> > This leaves me trying to work out the best way to migrate across to the
> > new drives.
>
> Recent kernels/mdadm can grow RAID-1 (and RAID-5):
>
> http://www.debian-administration.org/articles/424
>
> If not confident with that then I would do the "take one disk out of
> the mirror, make new mirror on it in degraded mode, shoft data over,
> add old disk" routine you already mentioned.

** end quote [Andy Smith]

That looks interesting, I'll have to have a read up on the process, from
a quick glance it looks as though it may do the trick along the
following lines:

o remove failed drive
o create new partition table on new drive with new sizes
o rebuild RAID mirror using new drive (wasting space)
o remove old smaller drive - this will still be available as a backup :)
o install second new drive and rebuild mirror
o use mdadm --grow to make the extra space available
o use resize2fs to make use of the extra space

That sounds like a good working plan, now to read up and then give it a
go - since I am pulling an existing working drive during the process the
data will be save on that before I do any nasty, dangerous resizing
stuff :)

Thanks for that, I thought I'd scanned through most of the Debian
Administration stuff by now, but clearly not!!

-- 
Paul Tansom | Aptanet Ltd. | http://www.aptanet.com/
====================================================================                                
Aptanet Ltd. | Registered in England | Company No: 4905028                                          
Registered Office:                                                                                  
Crawford House, Hambledon Road, Denmead, Waterlooville, Hants., PO7 6NU