1826086 Members
4532 Online
109690 Solutions
New Discussion

Re: vgimport

 
SOLVED
Go to solution
Peter Brimacombe
Frequent Advisor

vgimport

I plan to move a volume group from a K210 to an new L server. The volume group exists on six physical disk drives installed in an old storage enclosure (A3311) on the K210 and I plan to move them to a new storage enclosure (A3312) on the L server.

I have found document KBAN00000066 which describes how to move a volume group from one HP-UX system to another.

How does vgimport reconcile the fact that the new pv_names are different from the old?

The old pvnames are
/dev/dsk/c0t10d0
/dev/dsk/c0t11d0
/dev/dsk/c0t12d0
/dev/dsk/c0t13d0
/dev/dsk/c0t14d0
/dev/dsk/c0t15d0

I don't know yet what the new names will be, I plan to set the scsi address to correspond to the old, so I think they will be something like
/dev/dsk/c6t10d0
/dev/dsk/c6t11d0
/dev/dsk/c6t12d0
/dev/dsk/c6t13d0
/dev/dsk/c6t14d0
/dev/dsk/c6t15d0
5 REPLIES 5
Thierry Poels_1
Honored Contributor

Re: vgimport

Hi Peter,

that's the idea of vgimport ;)
you can move to other disk addresses and even to another VG-name.
good luck,
Thierry.
All unix flavours are exactly the same . . . . . . . . . . for end users anyway.
Mark Mitchell
Trusted Contributor

Re: vgimport

You can use the -m mapfile option to help resolve the differences
Dave Wherry
Esteemed Contributor
Solution

Re: vgimport

vgimport does not really reconcile it. You explicitly tell it which pv's to import. If they are all there, meaning all the pieces of the logical volumes, it works. Hardware paths and device can change. It does not matter as long as all of the physical pieces are there.
Patrick Wallek
Honored Contributor

Re: vgimport

There is an option to vgexport/vgimport that you can use so that you do not have to explicitly specify the path to all of the disks you are importing from.

On your old system do this:

vgexport -m mapfile.name -s -p /dev/vg??

Note: The -p option is for preview. If you want to generate the map file but not wipe out the VG on the old machine, use that. The '-s' option is the magic one here. It will write a VGID (a string of letters and numbers) to the map file. This string allows you to vgimport using the map file, and vgimport will look for ALL drives on the system that have that VGID string.

On your new system do:

mkdir /dev/vg??
mknod c 64 0x0?0000 /dev/vg??/group
vgimport -s -m mapfile.name /dev/vg??

You now have your volume group on your new machine. Mount you lvols and you are ready to go.
Dave Wherry
Esteemed Contributor

Re: vgimport

Patrick,
Thanks for elaborating on that. I always use the map files. I was just looking at the lvol information. I had overlooked the VGID info.
I think the reason I do that is one time I vgexported a UX10.20 vg. Then I imported it on a 11.0 system. I had trouble with the mapfile so I deleted the VGID line, explicitely named all the pv's and it worked fine. It's just the habit I got into. Both ways work. Using the VGID does make it simpler.
Thanks.