Operating System - HP-UX
1837195 Members
2416 Online
110114 Solutions
New Discussion

LVM vg Information without activation of vg

 
BMW UNIX-Team W2
New Member

LVM vg Information without activation of vg

Hi,

if I take the entries of the /etc/lvmtab and go through all the devices with echo "0x2008?4X" | adb I can get the PVID and VGID of the devices without having to activate the VG. Is there any other information which can be found that way (like lvols of the vg, pv belonging to lvol and so on)? Is there any document describing such infos?

I am using this information as part of a configuration management tool, which otherwise couldn't collect information on volume groups deactivated on all nodes at the moment.

Regards,
Andreas
5 REPLIES 5
Bharat Katkar
Honored Contributor

Re: LVM vg Information without activation of vg

Well, you can find what lv's are by going into /dev/vgxx
That is what i can tell u.
regards,
You need to know a lot to actually know how little you know
Ravi_8
Honored Contributor

Re: LVM vg Information without activation of vg

Hi,

There is no any tool to identify vg if it is deactivated. There is a non HP tool "cfg2html" (you have to search in web) which i heard that it can give all the info
never give up
Dietmar Konermann
Honored Contributor

Re: LVM vg Information without activation of vg

If possible you could activate the VG read-only temporarily. Getting the information directly from the LVMREC would be rather complicated... I don't know any tool that provides that functionality.

Best regards...
Dietmar.
"Logic is the beginning of wisdom; not the end." -- Spock (Star Trek VI: The Undiscovered Country)
Ashwani Kashyap
Honored Contributor

Re: LVM vg Information without activation of vg

If the Vg was previously active and the vg backup was done , some information could be obtained from the vg.conf files in the /etc/lvmconf directory .
Rita C Workman
Honored Contributor

Re: LVM vg Information without activation of vg

Well...you can run strings on certain files and gather some info.
Like strings on vgxx.conf will tell you what disks (c-t-d-) belong to this one. But then again so would strings on /etc/lvmtab

And you could cat/more on any vgxx.mapfile to see what lvol names were associated to it. Of course that doesn't tell you anything more than the lvol name, and not which disk any lvol was on.

So unless you activate as Dietmar mentioned in read only...the important information only comes up when the vg is 'active.

Others may know another way,
Rita