Operating System - HP-UX
1831406 Members
3672 Online
110025 Solutions
New Discussion

vgimport fails for existing volume group

 
SOLVED
Go to solution
Mihails Nikitins
Super Advisor

vgimport fails for existing volume group

Hi,

I have a shared volume group in MC/Service guard environment. Imagine I add a disk to volume group by vgextend on primary node.

Question.

How to transfer updated volume group information to another node? I can't transfer vg configuration fo existing group by vgimport command.

# vgimport -s -m /tmp/vgdb.map /dev/vgdb
vgimport: Volume group "/dev/vgdb" already exists in the "/etc/lvmtab" file.

Thanks an points in advance!

BR,
Mihails



KISS - Keep It Simple Stupid
5 REPLIES 5
Pete Randall
Outstanding Contributor

Re: vgimport fails for existing volume group

Mihails,

I'm not in a MCSG environment, but wouldn't you have to export it first on the second node so that you can then import it?


Pete


Pete
A. Clay Stephenson
Acclaimed Contributor
Solution

Re: vgimport fails for existing volume group

You simply do a vgexport /dev/vgdb first. You then start the vgimport process from scratch -- create /dev/vgdb; mknod /dev/vgdb/group c 64 0x?????? and then vgimport -s.
If it ain't broke, I can fix that.

Re: vgimport fails for existing volume group

Pete's correct Mihails,

You need to:

vgexport /dev/vgdb

On the secondary node before doing the vgimport.

HTH

Duncan

I am an HPE Employee
Accept or Kudo
Bryan D. Quinn
Respected Contributor

Re: vgimport fails for existing volume group

Hello,

Here is what we do in our cluster to add a disk to an existing VG on the failover node:

vgexport /dev/vgXX

mknod /dev/vgXX/group c 64 0xYY0000

vgimport /dev/vgXX /dev/dsk/cXtYdZ ....

or

vgimport -s

then we do a

vgchange -a r /dev/vgXX
(activate read only)

vgchange -a n /dev/vgXX

Hope this helps!
-Bryan
Mihails Nikitins
Super Advisor

Re: vgimport fails for existing volume group

Thank you for input! RTFM man vgexport. :-)
When using physical volume groups, one should also correct /etc/lvmpvg file because vgexport deletes entries from there.

BR,
Mihails
KISS - Keep It Simple Stupid