On Fri, Oct 30, 2009 at 07:54:22PM +0100, Gilles Mocellin wrote:
> Le Friday 30 October 2009 06:01:21 Israel Garcia, vous avez écrit :
> > Sorry if it's OT, but we have a debian lenny with a big VG1 a some LVs
> > inside and want to move all LV's  from VG1 to another VG2 located in
> > other server. Is it possible?
> > 
> > I've searched the web with no success.
> > 
> > thanks.
> 
> You also have the option to go through a big external disk :
> 1) plug the external disk in your server 1
> 
> 2) add the disque to VG1
>     - pvcreate /dev/sdXY (the external drive, or a partition on the external 
> drive)
>     - vgextend VG1 /dev/sdXY
> 
> 3) move the data to the external disk with pvmove (2 solutions)
>     - pvmove -n LV1 /dev/sdXY for each LV or
>     - pvmove /dev/sdAB /dev/sdXY for each PV in VG1 (if there is only one, 
> it's just one command comparing to solution 1)

aren't you missing a step to that the pv out of the vggroup ?

> 
> 4) deactivate VG1 on server 1
>      - vgchange -a n VG1 (you can delete it after, I don't think it's wise to 
> delete it now)
> 
> 5) unplug the external drive, and plug it to server 2
> 
> 6) add the PV on the external drive to VG2 on server 2
>     - vgextend VG2 /dev/sdXY (perhaps a pvscan will be needed ?)
> 
> 7) Move the data to the disks of VG2
>     - pvmove /dev/sdXY (no destination needed, except if you really want 
> where 
> to put the data)
> 
> 8) remove the PV of external drive
>     - vgreduce VG2 /dev/sdXY
> 
> 9) you're done ! Unplug the external drive.



-- 
"See, the irony is that what they need to do is get Syria to get Hezbollah to 
stop doing this shit, and it's over."

        - George W. Bush
06/16/2006
St. Petersburg, Russia
to Tony Blair at the G8 summit

Attachment: signature.asc
Description: Digital signature

Reply via email to