linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* migrate single disk to RAID 1?
@ 2009-07-14  7:16 Ben Beuchler
  2009-07-14 10:06 ` John Robinson
  0 siblings, 1 reply; 6+ messages in thread
From: Ben Beuchler @ 2009-07-14  7:16 UTC (permalink / raw)
  To: linux-raid

I'd like to convert an existing partition to RAID 1 using a portion of
a new, blank drive.  All of the examples I've seen involve creating
the RAID device with the *empty* partition (sda4), copying the data
from the old partition to the new RAID, then adding the old partition
to the RAID set.

From my modest understanding of how linux software RAID works, it
seems I should be able to take an existing partition containing data
(in this case sdb4 mounted as /mail) and build a RAID 1 array with
something similar to this:

umount /dev/sdb4
mdadm --build /dev/md0 --level=1 -n2 /dev/sdb4 missing
mount /dev/md0 /mail
mdadm --add /dev/md0 /dev/sda4

Will that work?  Or am I misunderstanding something fundamental?

Thanks!

-Ben

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2009-07-14 16:15 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-14  7:16 migrate single disk to RAID 1? Ben Beuchler
2009-07-14 10:06 ` John Robinson
2009-07-14 11:13   ` berk walker
2009-07-14 15:44   ` Ben Beuchler
2009-07-14 16:00     ` Robin Hill
2009-07-14 16:15     ` Michal Soltys

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).