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

RE: [linux-lvm] Copying LVM from one system to another



Dieter,

Thanks very much, but the problem is I want be able to restore my LVM filesystems from a backup. This is why I came with the idea of booting the PC I want to restore from a USB stick. The idea is the stick has a copy of the backup client. The LVM filesystems are mounted under /restore and I restore all the data to /restore.

How do I tell LVM the data has moved? I've experimented using this method but I noticed devmapper complains when I boot the PC from the newly restored data.

Cheers

Shaun

-----Original Message-----
From: linux-lvm-bounces redhat com [mailto:linux-lvm-bounces redhat com] On Behalf Of Dieter Stüken
Sent: dinsdag 11 juli 2006 19:49
To: mingz ele uri edu; LVM general discussion and development
Subject: Re: [linux-lvm] Copying LVM from one system to another

Ming Zhang wrote:
> if HW is the same, why not use ghost or alike software to do a clone?

Don't "clone" the LVM PVs if you ever want to connect both disks simultaneously.
For normal partitions this is fine, as those are identified by the device
name. So you can easily distinguish /dev/hda1 from /dev/hdc1.

LVM however identifies the different VG/LV/PV by its content, regardless of
where the disks are connected. If you connect your LVM disk to a different
cable or controller, don't worry, it will be found automatically. If two disks,
however, look exactly the same, LVM gets confused. 

Instead you should connect both disk:

arrange booting from <newdisk>,
lvm from <olddisk> should still work, even if connected differently.

pvcreate <new disk>
vgextend <new disk>
pvmove <olddisk>
vgreduce <olddisk>

to migrate all LVM content to the new disk.

Dieter.

_______________________________________________
linux-lvm mailing list
linux-lvm redhat com
https://www.redhat.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/




Op dit e-mailbericht is een disclaimer van toepassing, welke te vinden is op http://www.xb.nl/disclaimer.html





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