Operating System - HP-UX
1753437 Members
5034 Online
108794 Solutions
New Discussion юеВ

Redundant VGID LV sneaked in

 
Ralph Grothe
Honored Contributor

Redundant VGID LV sneaked in

Hi,

yesterday I had to add new PVs to a MC/SG cluster package's shared VG.

While issuing the (preview) vgexport in order to create a map file for distribution to failback nodes, somehow (unfortunately unnoticed by me) a bogus VGID LV sneaked in:

# head -3 vgb01_20021212.map
VGID 29256fe4392e2fd8
1 VGID
1 lvol1

Today, when I wanted to extend the filesystems on the LVs I stumbled over the bogus LV and realized what happened.

As I wasn't sure, so far I only cleaned the LVM metadata from the cluster nodes that currently don't run the package,
and I still refrained from issueing an lvremove of VGID on the node that runs the package and has the real LV mounted.

Btw, when inspecting the LVM layout of this VG (and PVs) with the commands vgdisplay, lvdisplay, pvdisplay the bogus VGID LV appears to be treated as an alias (i.e. exactly same data, mounting of it fails but croaks device busy)

Any idea if it's safe to do the lvremove on the package holding node?

Regards
Ralph
Madness, thy name is system administration
6 REPLIES 6
John Palmer
Honored Contributor

Re: Redundant VGID LV sneaked in

This sounds like VGID has been created as a duplicate device file.

DON'T run lvremove. Just remove the device files /dev/vg??/VGID and /dev/vg??/rVGID.

Regards,
John
Carlos Fernandez Riera
Honored Contributor

Re: Redundant VGID LV sneaked in

Do a vgexport on the halted node, edit the map file and and remove line 1 VGID.

VGID 29256fe4392e2fd8
1 VGID
1 lvol1

Then vgimport again.
unsupported
Ralph Grothe
Honored Contributor

Re: Redundant VGID LV sneaked in

Carlos,

I had done this already when I cleaned the LVM config for the other nodes.

Madness, thy name is system administration
Ralph Grothe
Honored Contributor

Re: Redundant VGID LV sneaked in

John,

will simple removal of redundant device files suffice?

I think for instance vgdisplay will still list the bogus LV though.
(well, you could call this a mere cosmetic detriment)

The device files are all referenced through individual inodes:

# ll -i /dev/vgb01/*
2479 brw-r----- 1 root sys 64 0x080001 Mar 12 2001 /dev/vgb01
/VGID
2480 crw-r--r-- 1 root sys 64 0x080000 Mar 12 2001 /dev/vgb01
/group
2481 brw-r----- 1 root sys 64 0x080001 Mar 12 2001 /dev/vgb01
/lvol1
2482 crw-r----- 1 root sys 64 0x080001 Mar 12 2001 /dev/vgb01
/rVGID
2483 crw-r----- 1 root sys 64 0x080001 Mar 12 2001 /dev/vgb01
/rlvol1
Madness, thy name is system administration
Jean-Louis Phelix
Honored Contributor

Re: Redundant VGID LV sneaked in

Hi,

Yes, John is right, a simple removal is enough. Vgdisplay tries to find any information related to entries in /dev/vgXX. For example, if you create dummy entries (lvol and rlvol) with other minor numbers, vgdisplay will display them with a 0 size.

Regards.
It works for me (┬й Bill McNAMARA ...)
James R. Ferguson
Acclaimed Contributor

Re: Redundant VGID LV sneaked in

Hi Ralph:

I agree with John. Simply remove the "VGID" device files.

I built a volume group with a logical volume. I then inactivated it ('vgchange -a n') and created ('mknod') device files with the same minor number. Thus an 'ls -l /dev/vgXX/*' looks like your presentation.

When I activated the volume group and did a 'vgdisplay -v' you see a current LV count of <1> but an open LV count of <2>. Doing a 'lvdisplay -v' of the "real" LV or the one named "VGID" shows extent mapping to the same physical extents as you would expect.

Regards!

...JRF...