1777260 Members
2258 Online
109066 Solutions
New Discussion юеВ

vgimport

 
SOLVED
Go to solution
Steven Boyer
Advisor

vgimport

I have a one for one mapping for our VG with one PV.

On the cluster partner I need to run vgimport with the vgname and device name. do I have to list all the devices with paths to the disk or just the first one
14 REPLIES 14
Anshumali
Esteemed Contributor

Re: vgimport

Steven,
You didnt mention the version of OS, ans should differ for 11.11 and 11.31.
For 11.11, it has to be mentioned all paths.
Dreams are not which you see while sleeping, Dreams are which doesnt allow you to sleep while you are chasing for them!!
Deepak Kr
Respected Contributor

Re: vgimport


Two choices:

You can use -s option available in vgexport to search all required disk devives for you.
e.g.
vgexport -vpsm /tmp/map.file vgname

or

You can specify all the disks those are part of vg

vgexport -vpm /tmp/map.file vgname disk lists


on all other cluster nodes:

# mkdir /dev/vgname
#mknod /dev/vgoracle/group c 64 0x0x0000

x= vg no.....check in /dev dir

#vgimport -s -m /tmp/map.file /dev/vgname

"There is always some scope for improvement"
Prashanth Waugh
Esteemed Contributor

Re: vgimport

Hi Steven

following are the steps
first take the minor no from the node on which you are doing vgexport for that vg

1) ll /dev//group
2)on primary node run the vgexport -v -s -p -m /tmp/

3) on another cluster node
run the following command
#ll /dev/vgname/group
take the major and minor no
#vgexport /dev/vgname
#mkdir /dev/vgname
#mknod /dev/vgname/group c
#vgimport -s -m /tmp/vgname.map /dev/vgpname

Regards
Atul
For success, attitude is equally as important as ability
Prashanth.D.S
Honored Contributor

Re: vgimport

Hi Steven,

Yes if you have created the map file without -s option you need to specify only the disk device name /dev/dsk/cxtxdx.

#vgimport -m / / /dev/dsk/cxtxdx

if you had exported the mapfiles
with -s option then no need to specify the disk device file name as -s would create map file with vgid's.

Best Regards,
Prashanth
Steven Boyer
Advisor

Re: vgimport

if I use vgimport with the device file, why do I need to use the -m option for maps.
Anka
Trusted Contributor
Solution

Re: vgimport

because of the logical volumes.
for example if you do not use it the names of the logical volumes after the import will be the default - lvol 1 2 3 ...

and if you use the -m option you will get the real names, as you have created them...
Steven Boyer
Advisor

Re: vgimport

and this is faster than using the -s option. what happens if I use the wrong device file
Prashanth Waugh
Esteemed Contributor

Re: vgimport

Hi steven,

Pls assign the points as per ITRC forum.It will encourage the people to give the ans and spend their valuable time.

Reagrds
Atul

For success, attitude is equally as important as ability
Court Campbell
Honored Contributor

Re: vgimport

just do a

vgexport -p -s -m /tm/vgXX.map /dev/vgXX

then scp the map file to the other server.

then

create the vg dir , ex.

mkdir /dev/vgXX

then create the group file, and then

vgimport -s -m /tmp/vgXX.map /dev/vgXX

This is all in the serviceguard manuals that can be viewed and downloaded from ttp://docs.hp.com

"The difference between me and you? I will read the man page." and "Respect the hat." and "You could just do a search on ITRC, you don't need to start a thread on a topic that's been answered 100 times already." Oh, and "What. no points???"
Court Campbell
Honored Contributor

Re: vgimport

> and this is faster than using the -s option. > what happens if I use the wrong device file

You want to use the -s on the vgexport so that it puts the vgid in the mapfile. then the vgimport will get the vgid and scan the disks looking for that vgid on the other host. the vgid is stored in the vgra is what will let each server know which disks belong to which volume groups.
"The difference between me and you? I will read the man page." and "Respect the hat." and "You could just do a search on ITRC, you don't need to start a thread on a topic that's been answered 100 times already." Oh, and "What. no points???"
Steven Boyer
Advisor

Re: vgimport

Yes I have those instructions and executed them but, this process was taking to long and I was looking for an alternative to using the -s option. We have ~50 VG, the last guy to import a VG on our system said it took over 5hrs at that rate it will take over 3 weeks to import all our VG.
Court Campbell
Honored Contributor

Re: vgimport

Sorry, but I have never had a vgexport/vgimport take that long. But then again I have never had that many vg's. I assume the vgexport runs pretty fast, but the vgimport is what is taking so long. How many disks are presented to the host?

ioscan -fuC disk | wc -l

will give you a close figure. I guess if it has to scan a lot if disks that could take a while.
"The difference between me and you? I will read the man page." and "Respect the hat." and "You could just do a search on ITRC, you don't need to start a thread on a topic that's been answered 100 times already." Oh, and "What. no points???"
john123
Trusted Contributor

Re: vgimport

What storage you are using.?
There would be some storage specific commands to find out the device name of the disks in the second node which corresponds the disk device name in the first node.

And then use -f option with disk file name while vgimport in the second node instead of using -s option
It will not scan all your disks and so it will be faster.



HTH
John
Steven Boyer
Advisor

Re: vgimport

using the -f options on the partner isnt that using the device number as seen by the primary and not the partner.

Its my understanding that the partner needs to have the list of devices as seen by the partner not the primary.