Operating System - HP-UX
1834170 Members
1937 Online
110064 Solutions
New Discussion

Help !!!! with LVM problems ....

 
SOLVED
Go to solution
Chapaya
Frequent Advisor

Help !!!! with LVM problems ....

Hello ,
I have a cluster with 2 nodes ,
with 3 vg's .
i cant activate vg01,vg02 on one server because it doesnt exist in /etc/lvmtab .

what should i do so the the server will "see" the vg's ?

Thanks,
Eran .
4 REPLIES 4
James Murtagh
Honored Contributor

Re: Help !!!! with LVM problems ....

Hi Eran,

You need to use the vgimport command to make the VG visible on the host. You have to create the directory first of course:

# mkdir /dev/vg01
# mknod /dev/vg01/group c 64 0x010000

Note the minor number here is the default numbering, if you don't have any other VGs you should be fine. Just make sure it is unique.

The vgimport command is fairly straightforward, more so if your lvols are just the standard names like lvol1 etc. If they are custom names you will need to create a mapfile from the live host:

# vgexport -m /var/tmp/vg01.map -p vg01

Then just ftp the file to the other server and import it:

# vgimport -m /var/tmp/vg01.map vg01

Your disk devices in the VG should ALL be listed.

To be safe it is worth deactivating the VG on the live host, although I assume it is as you are trying to activate it on the other.

Regards,

James.
Sridhar Bhaskarla
Honored Contributor

Re: Help !!!! with LVM problems ....

Hi Eran,

James gave you the procedure. There are couple of things I would like to add.

1. Do an ll /dev/*/group on the server where the VGs are good. Use the same minor numbers on the failover server. For ex., if /dev/vg01/group has the minor number 0x010000, then use the same on the other node.

2. You can use "-s" option to create the map files. This will automatically scan the disks and import the volume groups. On the primary server do.

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

Copy the above map file to the secondary server where vg01 is missing.

Then on the secondary server do

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

This should get your vg01. Repeat the same for vg02. Do not activate the VGs (vgchange -a y). It will be taken care by the Serviceguard when the package fails over.

Once this is done, you should be able to "see" the vgs.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Michael Steele_2
Honored Contributor
Solution

Re: Help !!!! with LVM problems ....

(* Everything listed below should produce identical results in the live node. *)

Little concerned about the sudden loss. So verify the existence in /etc/lvmconf where they should also exist.

A1) Check the disks using 'vgcfgrestore':

vgcfgrestore -f /dev/lvmconf/vg01.conf -l
vgcfgrestore -f /dev/lvmconf/vg01.conf -l

A2) You can see these disks via 'ioscan'?

ioscan -fnkC disk

A3) And the HBA's are intact? (* fiber channel adapters *)

ioscan -fnkC fc

fcmsutil /dev/td0
fcmsutil /dev/td1
fcmsutil /dev/td2

A4) In all reports of 'fcmsutil' the state = ready? And the topology is correct? (* point to point, AC-FL, for example *)

B) Note Sridhar's procedure to reconstruct these vg.s.

C) The vgs, lvs and fs' are listed in the package.cntl file. Are they there?

vi /etc/cmcluster/package/package.cntl

D) Use 'cmcheckconf' to verify the package.

cmcheckconf -P /etc/cmcluster/package/package.conf (* Note: Use the package.conf file *)

E) Now is not the time to failover.

cmviewcl -v
(* Both nodes report OK? *)

cmscancl -f /tmp/file
vi /tmp/file

(* Check this file carefully and attach any questions *)

cmmodpkg -e -n node package (* enable node2 for failover *)
Support Fatherhood - Stop Family Law
Chapaya
Frequent Advisor

Re: Help !!!! with LVM problems ....


I can "see" the vg's !!!

Thanks you all for your help ,
and to Michael for giving extra advices , keep on !!!

Best Rergards,
Eran .