* RAID10 - migrating disks without failing/degrading array?
@ 2009-10-02 18:22 David Rees
[not found] ` <7d86ddb90910021836h537e2af6h552b7c89af37d612@mail.gmail.com>
2009-10-13 22:20 ` Bill Davidsen
0 siblings, 2 replies; 4+ messages in thread
From: David Rees @ 2009-10-02 18:22 UTC (permalink / raw)
To: linux-raid
I've got an 8 disk RAID10 array (near2 layout) where I am moving data
off some older disks onto newer disks.
Currently what I'm doing is adding the newer disks as spares and then
failing/removing the older disks one at a time.
This works fine, but leaves me with an hour or so of running the array
degraded while the spare drive syncs up which leaves me open for
data-loss during this time period.
It seems like I should be able to add a drive as a directly
replacement for one of the drives I'm pulling out (so I temporarily
end up with 3-copies of that chunk instead of 2) until I pull
fail/remove the older disk. If I was using RAID0 striped over RAID1
mirrors, for example, I know this is possible.
Is this possible to do with RAID10?
Thanks
Dave
^ permalink raw reply [flat|nested] 4+ messages in thread[parent not found: <7d86ddb90910021836h537e2af6h552b7c89af37d612@mail.gmail.com>]
* Re: RAID10 - migrating disks without failing/degrading array?
[not found] ` <7d86ddb90910021836h537e2af6h552b7c89af37d612@mail.gmail.com>
@ 2009-10-03 2:53 ` David Rees
2009-10-03 8:42 ` Tom Carlson
0 siblings, 1 reply; 4+ messages in thread
From: David Rees @ 2009-10-03 2:53 UTC (permalink / raw)
To: Ryan Wagoner; +Cc: linux-raid
(Re-adding linux-raid to CC)
On Fri, Oct 2, 2009 at 6:36 PM, Ryan Wagoner <rswagoner@gmail.com> wrote:
> On Fri, Oct 2, 2009 at 2:22 PM, David Rees <drees76@gmail.com> wrote:
>> It seems like I should be able to add a drive as a directly
>> replacement for one of the drives I'm pulling out (so I temporarily
>> end up with 3-copies of that chunk instead of 2) until I pull
>> fail/remove the older disk. If I was using RAID0 striped over RAID1
>> mirrors, for example, I know this is possible.
>>
>> Is this possible to do with RAID10?
>
> You could stop the array and use dd to copy the old disks to the new
> ones. Then just start up the array on the new disks.
Yeah, that would work, but the goal is to do the migration without any downtime.
eSATA hot-swap even in inexpensive enclosures works pretty well these
days. There are slight hiccups as the drives get rescanned, but it's
not too noticable.
-Dave
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: RAID10 - migrating disks without failing/degrading array?
2009-10-03 2:53 ` David Rees
@ 2009-10-03 8:42 ` Tom Carlson
0 siblings, 0 replies; 4+ messages in thread
From: Tom Carlson @ 2009-10-03 8:42 UTC (permalink / raw)
To: David Rees; +Cc: Ryan Wagoner, linux-raid
You could also use mdadm..... :-)
Say you have raid10 array md0 with members sda1 sdb1 sdc1 sdd1 and you
wish to swap out sdd1 for sde1, with as little time for massive fail
as possible...:
Add a bitmap (bitmap chunk may need tweaking here depending on size of devices)
mdadm -Gb internal --bitmap-chunk=1024 /dev/md0
Fail and remove device:
mdadm --fail /dev/md0 /dev/sdd1
mdadm --remove /dev/md
Build (NOT create) a new raid1:
mdadm --build /dev/13 -ayes --level=1 --raid-devices=2 /dev/sdd1 missing
Add this new raid1 to md0:
mdadm /dev/md0 --re-add /dev/md32
Add the new disk to the temp raid1:
mdadm /dev/md32 --add /dev/sde1
[Now wait a while for md32 to resync. md0 should not have had to
resync at all if the array was not in use. Hurrah bitmap!]
Remove the raid1:
mdadm /dev/md0 --fail /dev/md32
mdadm /dev/md0 --remove /dev/md32
mdadm --stop /dev/md32
Re-add the new disk
mdadm /dev/md0 --re-add /dev/sde1
Zero superblock of old disk
mdadm --zero-superblock /dev/sdd1
2009/10/3 David Rees <drees76@gmail.com>:
> (Re-adding linux-raid to CC)
>
> On Fri, Oct 2, 2009 at 6:36 PM, Ryan Wagoner <rswagoner@gmail.com> wrote:
>> On Fri, Oct 2, 2009 at 2:22 PM, David Rees <drees76@gmail.com> wrote:
>>> It seems like I should be able to add a drive as a directly
>>> replacement for one of the drives I'm pulling out (so I temporarily
>>> end up with 3-copies of that chunk instead of 2) until I pull
>>> fail/remove the older disk. If I was using RAID0 striped over RAID1
>>> mirrors, for example, I know this is possible.
>>>
>>> Is this possible to do with RAID10?
>>
>> You could stop the array and use dd to copy the old disks to the new
>> ones. Then just start up the array on the new disks.
>
> Yeah, that would work, but the goal is to do the migration without any downtime.
>
> eSATA hot-swap even in inexpensive enclosures works pretty well these
> days. There are slight hiccups as the drives get rescanned, but it's
> not too noticable.
>
> -Dave
> --
> To unsubscribe from this list: send the line "unsubscribe linux-raid" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: RAID10 - migrating disks without failing/degrading array?
2009-10-02 18:22 RAID10 - migrating disks without failing/degrading array? David Rees
[not found] ` <7d86ddb90910021836h537e2af6h552b7c89af37d612@mail.gmail.com>
@ 2009-10-13 22:20 ` Bill Davidsen
1 sibling, 0 replies; 4+ messages in thread
From: Bill Davidsen @ 2009-10-13 22:20 UTC (permalink / raw)
To: David Rees; +Cc: linux-raid
David Rees wrote:
> I've got an 8 disk RAID10 array (near2 layout) where I am moving data
> off some older disks onto newer disks.
>
> Currently what I'm doing is adding the newer disks as spares and then
> failing/removing the older disks one at a time.
>
> This works fine, but leaves me with an hour or so of running the array
> degraded while the spare drive syncs up which leaves me open for
> data-loss during this time period.
>
> It seems like I should be able to add a drive as a directly
> replacement for one of the drives I'm pulling out (so I temporarily
> end up with 3-copies of that chunk instead of 2) until I pull
> fail/remove the older disk. If I was using RAID0 striped over RAID1
> mirrors, for example, I know this is possible.
>
> Is this possible to do with RAID10?
>
In a slow, ugly, complex way, as someone described in another response.
It involves using raid-1, and I suggest checking the write-mostly option
as well, and involves some short time without the 2nd copy configured
(and using check may not test everything on raid-10). Use a bitmap if
you're not already.
There is at least one other current thread regarding the need for a
"clone member" feature in md, but unless someone with time and skills
also has the problem, I doubt it's going to get added soon.
--
Bill Davidsen <davidsen@tmr.com>
Unintended results are the well-earned reward for incompetence.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-10-13 22:20 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-02 18:22 RAID10 - migrating disks without failing/degrading array? David Rees
[not found] ` <7d86ddb90910021836h537e2af6h552b7c89af37d612@mail.gmail.com>
2009-10-03 2:53 ` David Rees
2009-10-03 8:42 ` Tom Carlson
2009-10-13 22:20 ` Bill Davidsen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).