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

Re: [linux-lvm] How to 'copy' a volume?



On Thu, 3 Jan 2008, Erich Weiler wrote:

> I know that LVM has the 'snapshot' capability.  But this doesn't look 
> like it's what I need, as I don't want my duplicate volume to have any 
> affiliation with the original at all.  I actually want to duplicate VM 
> to take up just as much space as the first and be completely independent 
> of any changes on the first.  Is there a way of achieving this?  Could I 
> maybe simply make sure the volume is unmounted and not in use, then copy 
> the /dev/mapper/myvolume file to something else?  I bet it's more 
> involved than that...  :)

That's all these is to it.  You can also take a snapshot first, then
copy the snapshot.  With a journalling filesystem (e.g. ext3), it will recover
the copy when mounted.  Caveat: if you are mounting by filesystem label
(LABEL=foo), then both the copy and the snapshot will have duplicate labels,
and the filesystem will refuse to mount.  Use e2label (for ext3) to change the
label of the copy.  If not mounting by label, the duplicates won't matter.

-- 
	      Stuart D. Gathman <stuart bmsi com>
    Business Management Systems Inc.  Phone: 703 591-0911 Fax: 703 591-6154
"Confutatis maledictis, flammis acribus addictis" - background song for
a Microsoft sponsored "Where do you want to go from here?" commercial.


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