LVM and VxVM

Copy logical volumes between volumegroups

 
Bruno Bossier_1
Regular Advisor

Copy logical volumes between volumegroups

Can I copy a raw device (in a RAC environment) between volumegroups ? The target lv is in a different vg than the source lv.

What method should I use best ?

Bruno
4 REPLIES 4
Steven E. Protter
Exalted Contributor

Re: Copy logical volumes between volumegroups

You might be able to do this:

vgexport the volume group including the raw devicee.

vgimport it into an new volume group.

That does the whole volume group and you want to do one logical volume.

You might be able to dump it and then read the dump.

The supported methodology from the oracle standpoint would be to export the data from the raw disk area and then set up a new empty raw disk area in the new volume group and import the data.

Another reason why at my previous shop we kept our data on filesystems.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Bruno Bossier_1
Regular Advisor

Re: Copy logical volumes between volumegroups

Hmm ... can't export the volumegroup as it is production and should stay online.

I thought this :

- add new disks (from a different storage arry) to existing vg
- create mirrors on these new disks
- split lv's

Unfortunately, lvsplit does not work on shared vg's.

Maybe dd ?
Alex Lavrov.
Honored Contributor

Re: Copy logical volumes between volumegroups

You can't copy the raw device of the living database. Physically you can, but later it won't work because when ut's under use it's not consistent.
I don't give a damn for a man that can only spell a word one way. (M. Twain)
Bruno Bossier_1
Regular Advisor

Re: Copy logical volumes between volumegroups

We would off course stop the database first ....