Operating System - HP-UX
1846214 Members
5589 Online
110255 Solutions
New Discussion

Equivalent of "LV IDENTIFIER"

 
vikrantl
Advisor

Equivalent of "LV IDENTIFIER"

I'm trying to find the ID field on the volume objects {Logical Volume and Volume Group)
On AIX we have the field as "LV IDENTIFIER" and can be queried using lslv CLI.
Can anyone let me know the field that specifies the ID and the CLI to query it?
vikrantl
8 REPLIES 8
Stuart Abramson_2
Honored Contributor

Re: Equivalent of "LV IDENTIFIER"

What is the purpose of what you want?

What do you query "lslv CLI" to learn?

Are you trying to find out if it is mounted, how big it is, etc.? What?

vikrantl
Advisor

Re: Equivalent of "LV IDENTIFIER"

I want to find the unique id for the volume.

Using lslv I get the LV IDENTIFIER" for the lvm volume on AIX.

I want to find the id for my book keeping, and further I'm planning to move the volumegroup to another similar HP machine.
So probably the ID would be my index key.
vikrantl
RAC_1
Honored Contributor

Re: Equivalent of "LV IDENTIFIER"

I could not get what exactly and why you want t it. If I am correct, if volume group has been set to auto backup,(whenevr changes are made to VG, it backs up volume config data)
the file /etc/lvmconf/vgxx.conf will have vgid in it. This is not text file.

strings /etc/lvmconf/vgxx.conf will give that detail.

Anil
There is no substitute to HARDWORK
Stuart Abramson_2
Honored Contributor

Re: Equivalent of "LV IDENTIFIER"

We don't understand your question.

Maybe if you told us your complete objective, we could offer some help.

Every VG has a minor number associated with it:
....ll /dev/*/group

Every LV has an "index" associated with it:
....ll /dev/vg00

Every VG has a "VGID" associated with it:
....vgexport -p vgname -m mapfile; head mapfile

Every LV has a mapfile index associated with it:
cat mapfile

They all have differest uses....

If you vgexport a VG from one system and vgimport it on another system, you want to copy the "mapfile" over.
vikrantl
Advisor

Re: Equivalent of "LV IDENTIFIER"

I want this minor number and index fields, so that I can list the objects uniquely, even as I export the objects on various hosts.

How can I get the minor number and the index?
vikrantl
Stuart Abramson_2
Honored Contributor

Re: Equivalent of "LV IDENTIFIER"

Look at the commands in my response above.
vikrantl
Advisor

Re: Equivalent of "LV IDENTIFIER"

Well the `ll /dev/vg00/group` is helping me,
but do you know any simple CLI that will also give the VG-ID.
Is this VG-ID unique across the hosts?
----------------------------------------
# lvm11 -p -d /dev/rdsk/c1t2d0 | more
...
...
/* The physical volume ID. */ 2000252410 965817345i.e.
pvcreate(1m) was run on CPU with ID 2000252410 at Wed Aug 9 12:35:45
2000
/* The volume group ID. */ 2000252410 965817462i.e.
vgcreate(1m) was run on CPU with ID 2000252410 at Wed Aug 9 12:37:42
vikrantl
Jeff Schussele
Honored Contributor

Re: Equivalent of "LV IDENTIFIER"

Hi,

I think what you're looking for is the VGID for that volume group.
If so here's a method

echo 0x2010?2X|adb /dev/dsk/cXtYdZ|expand|tr -d " "

This should yield a result like

2010: 778B50B1 3D5D3888

If you drop the 2010: & combine the next two fields - there's your VGID

778B50B13D5D3888

HTH,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!