Operating System - HP-UX
1837127 Members
3155 Online
110112 Solutions
New Discussion

need steps for exporting and importing volume group from one server to another server

 
Marvike
Frequent Advisor

need steps for exporting and importing volume group from one server to another server

Dear All,

1) Can any one tell me steps for exporting and importing volume group from one server to another server.
2) Do both server needs to have access to same LUN for exporting and importing volume group from one server to another server.
3) If there is any data in existing volume which is to be exported will it effect the data while exporting to another server.How to do this?
7 REPLIES 7
James R. Ferguson
Acclaimed Contributor

Re: need steps for exporting and importing volume group from one server to another server

Hi:

> 1) Can any one tell me steps for exporting and importing volume group from one server to another server.

You use 'vgexport' and 'vgimport. The manpages have some good examples.

> 2) Do both server needs to have access to same LUN for exporting and importing volume group from one server to another server.

No, the physical hardware address can differ. If you have 'vgexport'ed with a mapfile containing the VGID of the volume group ('-s') then this can be used during the 'vgimport' to find the volumes again on the receiving server. Otherwise, you can specify the physical paths at which to find the disk(s) with the 'pv_path' argument(s) on the command line or in a file given by the '-f infile' argument.

> 3) If there is any data in existing volume which is to be exported will it effect the data while exporting to another server.

No, a 'vgimport'/'vgexport' operation does not disturb volume group data. The process operates by examining the LVM metadata only. Filesystems in logical volumes of the volume group in question are not disturbed.

Regards!

...JRF...
Benoy Daniel
Trusted Contributor

Re: need steps for exporting and importing volume group from one server to another server

vgexport -p -m -s

copy the copy file to destination server

Map the lun to destination server

vgimport -m
bharat satsangi
Frequent Advisor

Re: need steps for exporting and importing volume group from one server to another server

vgexport -v -p -s -m /tmp/vgname.map vgname

copy this vgname.map to second server. its a binary file.

go to second server.

mkdir -p /dev/vgname
cd /dev/vgname
mknod /dev/vgname/group c 64 0x330000
vgimport -v -s -m vgname.map vgname
Suraj K Sankari
Honored Contributor

Re: need steps for exporting and importing volume group from one server to another server

Hi,
To do import and export 1st you need to login to nodeA suppose you need to export vg01

#vgexport -v -p -s -m /tmp/vg01.map vg01

FTP or SCP this map file to nodeB (suppose /tmp) now login to nodeB Create directory and group file and then import the map file

#mkdir -p /dev/vg01
#cd /dev/vg01
#mknod /dev/vg01/group c 64 0x010000
#vgimport -v -s -m /tmp/vg01.map vg01

Suraj
Taifur
Respected Contributor

Re: need steps for exporting and importing volume group from one server to another server

Hi,

For export/ import vg , procedure as follows,
Node1:
#vgexport -p -s -v -m /tmp/vg01.map /dev/vg01
#rcp /tmp/vg01.map node2:/tmp/vg01.map

Node2:
#mkdir /dev/vg01
#mknod /dev/vg01/group c 64 0x030000
#vgimport -s -v -m /tmp/vg01.map /dev/vg01

During vg export/import , close all application and for precaution take ignite backup and database backup.

Cheers/
Taifur
Robert Salter
Respected Contributor

Re: need steps for exporting and importing volume group from one server to another server

Bhujang,

You've only awarded points to 6 of 41 requests for help the past year!

Shame on you! Shame! Shame!

These nice people have gone out of their way to assist you with your questions and problems and this is how you acknowledge that help?

tsk! tsk!
Time to smoke and joke
Marvike
Frequent Advisor

Re: need steps for exporting and importing volume group from one server to another server

got required solution.