Operating System - HP-UX
1752565 Members
5623 Online
108788 Solutions
New Discussion юеВ

Re: Strange LVM V2.2 Problem with vgdisplay NOT working on LVM V2.2 data VG

 
SOLVED
Go to solution
noldi
Valued Contributor

Strange LVM V2.2 Problem with vgdisplay NOT working on LVM V2.2 data VG

Hi,

after recovering an HPVM via make_net_recovery / Ignite-UX that has a root vg vg00 (LVM1) and a data vg vg01 (LVM V2.2), we see strange behaviour: the fs are mounted but we don't seem to have proper access to the VG (see below).

Any idea what could be wrong here?

Thanks & Regards,

Arnold

--------------- snip here -------------------

uxas792:/etc # kcmodule | grep lvm
lvm static best
lvmp loaded best loadable, unloadable
uxas792:/etc #
uxas792:/etc #
uxas792:/etc # vgdisplay -v vg00
--- Volume groups ---
VG Name /dev/vg00
VG Write Access read/write
VG Status available
Max LV 255
Cur LV 8
Open LV 8
Max PV 16
Cur PV 1
Act PV 1
Max PE per PV 3195
VGDA 2
PE Size (Mbytes) 64
Total PE 945
Alloc PE 704
Free PE 241
Total PVG 0
Total Spare PVs 0
Total Spare PVs in use 0

--- Logical volumes ---
LV Name /dev/vg00/lvol1
LV Status available/syncd
LV Size (Mbytes) 2048
Current LE 32
Allocated PE 32
Used PV 1

LV Name /dev/vg00/lvol2
LV Status available/syncd
LV Size (Mbytes) 8192
Current LE 128
Allocated PE 128
Used PV 1

LV Name /dev/vg00/lvol3
LV Status available/syncd
LV Size (Mbytes) 2048
Current LE 32
Allocated PE 32
Used PV 1

LV Name /dev/vg00/lvol4
LV Status available/syncd
LV Size (Mbytes) 2048
Current LE 32
Allocated PE 32
Used PV 1

LV Name /dev/vg00/lvol5
LV Status available/syncd
LV Size (Mbytes) 10240
Current LE 160
Allocated PE 160
Used PV 1

LV Name /dev/vg00/lvol6
LV Status available/syncd
LV Size (Mbytes) 2048
Current LE 32
Allocated PE 32
Used PV 1

LV Name /dev/vg00/lvol7
LV Status available/syncd
LV Size (Mbytes) 8192
Current LE 128
Allocated PE 128
Used PV 1

LV Name /dev/vg00/lvol8
LV Status available/syncd
LV Size (Mbytes) 10240
Current LE 160
Allocated PE 160
Used PV 1


--- Physical volumes ---
PV Name /dev/disk/disk2_p2
PV Status available
Total PE 945
Free PE 241
Autoswitch On


uxas792:/etc #
uxas792:/etc #
uxas792:/etc # vgdisplay -v vg01
vgdisplay: Volume group "/dev/vg01" does not exist in the "/etc/lvmtab" file.
vgdisplay: Cannot display volume group "vg01".
uxas792:/etc #
uxas792:/etc # strings /etc/lvmtab
/dev/vg00
/dev/disk/disk2_p2
uxas792:/etc #
uxas792:/etc # strings /etc/lvmtab_p
/dev/vg01
A0000000000000001Wed Mar 30 12:44:27 20115a11bdee-5ac9-11e0-8d07-0017a4772800
/dev/disk/disk3
uxas792:/etc #
uxas792:/etc # ioscan -fnkNC disk
Class I H/W Path Driver S/W State H/W Type Description
===================================================================
disk 2 64000/0xfa00/0x0 esdisk CLAIMED DEVICE HP Virtual Disk
/dev/disk/disk2 /dev/disk/disk2_p2 /dev/rdisk/disk2 /dev/rdisk/disk2_p2
/dev/disk/disk2_p1 /dev/disk/disk2_p3 /dev/rdisk/disk2_p1 /dev/rdisk/disk2_p3
disk 3 64000/0xfa00/0x1 esdisk CLAIMED DEVICE HP Virtual Disk
/dev/disk/disk3 /dev/rdisk/disk3
uxas792:/etc #
uxas792:/etc # ls -ald /dev/vg0?/group
crw-r----- 1 root sys 64 0x000000 Mar 30 14:52 /dev/vg00/group
crw-r----- 1 root sys 128 0x001000 Mar 30 14:52 /dev/vg01/group
uxas792:/etc #
uxas792:/etc #
uxas792:/etc # pvdisplay /dev/disk/disk3
pvdisplay: Couldn't find the volume group to which
physical volume "/dev/disk/disk3" belongs.
pvdisplay: Cannot display physical volume "/dev/disk/disk3".
uxas792:/etc #
uxas792:/etc #
uxas792:/etc # bdf
Filesystem kbytes used avail %used Mounted on
/dev/vg00/lvol3 2097152 235816 1846872 11% /
/dev/vg00/lvol1 2097152 341672 1741840 16% /stand
/dev/vg00/lvol8 10485760 1681920 8735192 16% /var
/dev/vg00/lvol7 8388608 3092816 5254504 37% /usr
/dev/vg01/lvol8 31457280 4646203 25135388 16% /u08
/dev/vg01/lvol7 3145728 18263 2932006 1% /u07
/dev/vg01/lvol6 1048576 600341 420298 59% /u06
/dev/vg01/lvol5 31457280 4291619 25467811 14% /u05
/dev/vg01/lvol4 20971520 2923550 16920080 15% /u04
/dev/vg01/lvol3 2097152 1043942 987385 51% /u03
/dev/vg01/lvol2 1048576 173221 820647 17% /u02
/dev/vg01/lvol1 10485760 6936234 3327774 68% /u01
/dev/vg00/lvol6 2097152 21008 2060056 1% /tmp
/dev/vg00/lvol5 10485760 8459992 2009984 81% /opt
/dev/vg00/lvol4 2097152 82592 1998896 4% /home
uxas792:/etc #
uxas792:/etc #
uxas792:/etc # vgscan -v

The Volume Group /dev/vg00 was not matched with any Physical Volumes.
Scan of Physical Volumes Complete.
uxas792:/etc # vgscan -a -v -p

The Volume Group /dev/vg00 was not matched with any Physical Volumes.
uxas792:/etc #
uxas792:/etc # vgscan -a -v -p -N
Usage: vgscan
[-p]
[-v]
[-a]
"N": Illegal option.
2 REPLIES 2
VK2COT
Honored Contributor
Solution

Re: Strange LVM V2.2 Problem with vgdisplay NOT working on LVM V2.2 data VG

Hello,

Interesting problem. To get us started, let's try the following:

a) Firstly, The "-N" option cannot be used in
conjunction with the "-a", "-k", and "-B"
options.

b) Try this for vg01:

# vgscan -N -f /dev/vg01

c) By the way, what do these commands show:

# diskowner /dev/disk/disk3

# lvmadm -l

VK2COT
VK2COT - Dusan Baljevic
noldi
Valued Contributor

Re: Strange LVM V2.2 Problem with vgdisplay NOT working on LVM V2.2 data VG

Hi,

looks like "# vgscan -N -f /dev/vg01 has done the trick. Now vg01 shows up in the SMH too!

This is in an HPVM that has been redeployed to the same devices so maybe there were some stale data on the disk3 from the previous incarnation.

Thanks to VK2COT for hitting the nail!

Best Regards,

Arnold

----------------- cut here ------------------

uxas792:/ # lvmadm -l
--- Version 1.0 volume groups ---
VG Name /dev/vg00
PV Name /dev/disk/disk2_p2

--- Version 2.2 volume groups ---
VG Name /dev/vg01
PV Name /dev/disk/disk3

uxas792:/ #
uxas792:/ #
uxas792:/ # diskowner /dev/disk/disk3
Path /dev/disk/disk3 is owned by lvm.
uxas792:/ #
uxas792:/ # vgscan -N -f /dev/vg01
vgscan: The physical volume "/dev/disk/disk3" is already recorded in the "/etc/l vmtab_p" file.

*** LVMPTAB has been updated successfully.
uxas792:/ # vgdisplay -v vg01
--- Volume groups ---
VG Name /dev/vg01
VG Write Access read/write
VG Status available
Max LV 2047
Cur LV 9
Open LV 9
Cur Snapshot LV 0
Max PV 2048
Cur PV 1
Act PV 1
Max PE per PV 65536
VGDA 2
PE Size (Mbytes) 32
Unshare unit size (Kbytes) 1024
Total PE 6399
Alloc PE 3852
Current pre-allocated PE 0
Free PE 2547
Total PVG 0
Total Spare PVs 0
Total Spare PVs in use 0
VG Version 2.2
VG Max Size 2t
VG Max Extents 65536
Cur Snapshot Capacity 0p
Max Snapshot Capacity 2t

--- Logical volumes ---
LV Name /dev/vg01/lvol1
LV Status available/syncd
LV Size (Mbytes) 15360
Current LE 480
Allocated PE 480
Used PV 1

LV Name /dev/vg01/lvol2
LV Status available/syncd
LV Size (Mbytes) 1024
Current LE 32
Allocated PE 32
Used PV 1

LV Name /dev/vg01/lvol3
LV Status available/syncd
LV Size (Mbytes) 2048
Current LE 64
Allocated PE 64
Used PV 1

LV Name /dev/vg01/lvol4
LV Status available/syncd
LV Size (Mbytes) 15360
Current LE 480
Allocated PE 480
Used PV 1

LV Name /dev/vg01/lvol5
LV Status available/syncd
LV Size (Mbytes) 15360
Current LE 480
Allocated PE 480
Used PV 1

LV Name /dev/vg01/lvol6
LV Status available/syncd
LV Size (Mbytes) 2048
Current LE 64
Allocated PE 64
Used PV 1

LV Name /dev/vg01/lvol8
LV Status available/syncd
LV Size (Mbytes) 71680
Current LE 2240
Allocated PE 2240
Used PV 1

LV Name /dev/vg01/lvtng
LV Status available/syncd
LV Size (Mbytes) 160
Current LE 5
Allocated PE 5
Used PV 1

LV Name /dev/vg01/lv_tivoli
LV Status available/syncd
LV Size (Mbytes) 224
Current LE 7
Allocated PE 7
Used PV 1


--- Physical volumes ---
PV Name /dev/disk/disk3
PV Status available
Total PE 6399
Free PE 2547
Current pre-allocated PE 0
Autoswitch On
Proactive Polling On